Click here to Skip to main content
15,887,214 members
Home / Discussions / Web Development
   

Web Development

 
GeneralRe: Which language should I use out of javascript or php? Pin
Jeremy Falcon24-Mar-23 4:15
professionalJeremy Falcon24-Mar-23 4:15 
GeneralRe: Which language should I use out of javascript or php? Pin
Member 1595298026-Mar-23 0:04
Member 1595298026-Mar-23 0:04 
GeneralRe: Which language should I use out of javascript or php? Pin
Jeremy Falcon27-Mar-23 4:31
professionalJeremy Falcon27-Mar-23 4:31 
QuestionEnumerate a div pattern in html page Pin
_Flaviu14-Mar-23 0:28
_Flaviu14-Mar-23 0:28 
AnswerRe: Enumerate a div pattern in html page Pin
jsc4214-Mar-23 4:24
professionaljsc4214-Mar-23 4:24 
GeneralRe: Enumerate a div pattern in html page Pin
_Flaviu14-Mar-23 5:45
_Flaviu14-Mar-23 5:45 
GeneralRe: Enumerate a div pattern in html page Pin
_Flaviu14-Mar-23 22:08
_Flaviu14-Mar-23 22:08 
AnswerRe: Enumerate a div pattern in html page Pin
Jeremy Falcon20-Mar-23 9:15
professionalJeremy Falcon20-Mar-23 9:15 
QuestionArrange image and text in a div, div after div Pin
_Flaviu6-Mar-23 3:19
_Flaviu6-Mar-23 3:19 
AnswerRe: Arrange image and text in a div, div after div Pin
Richard Deeming6-Mar-23 4:26
mveRichard Deeming6-Mar-23 4:26 
GeneralRe: Arrange image and text in a div, div after div Pin
_Flaviu6-Mar-23 5:51
_Flaviu6-Mar-23 5:51 
GeneralRe: Arrange image and text in a div, div after div Pin
Richard Deeming6-Mar-23 22:55
mveRichard Deeming6-Mar-23 22:55 
GeneralRe: Arrange image and text in a div, div after div Pin
_Flaviu7-Mar-23 1:39
_Flaviu7-Mar-23 1:39 
GeneralRe: Arrange image and text in a div, div after div Pin
Zarchiver Apk17-Mar-23 19:27
Zarchiver Apk17-Mar-23 19:27 
QuestionEnglish to Arabic language change integrate in html Pin
Manish Kumar 2926-Feb-23 21:22
Manish Kumar 2926-Feb-23 21:22 
AnswerRe: English to Arabic language change integrate in html Pin
Andre Oosthuizen28-Feb-23 1:43
mveAndre Oosthuizen28-Feb-23 1:43 
Questionwhy doesn't the file I have submitted appear in the email? Pin
rahmat_ hasibuan10-Feb-23 4:03
rahmat_ hasibuan10-Feb-23 4:03 
AnswerRe: why doesn't the file I have submitted appear in the email? Pin
Andre Oosthuizen10-Feb-23 5:33
mveAndre Oosthuizen10-Feb-23 5:33 
AnswerRe: why doesn't the file I have submitted appear in the email? Pin
jschell10-Feb-23 10:01
jschell10-Feb-23 10:01 
QuestionWhat is the capability of Django to handle large amounts of data? Pin
Karl Shady26-Jan-23 19:44
Karl Shady26-Jan-23 19:44 
AnswerRe: What is the capability of Django to handle large amounts of data? Pin
jschell2-Feb-23 7:58
jschell2-Feb-23 7:58 
GeneralRe: What is the capability of Django to handle large amounts of data? Pin
Gulshan Negi6-Feb-23 19:53
professionalGulshan Negi6-Feb-23 19:53 
GeneralI am trying to send confirmed Person and Vehicle images to telegram. Pin
sesipod29-Dec-22 6:22
sesipod29-Dec-22 6:22 
I have been working on a script trying to get images sent over to a telegram group. Though I assume it's requiring the use of http://localhost:32168/v1/vision/detection and this does not seem to be working. I have given it my best shot if anyone else can shine some light on this.


# Set the path to the folder of images
$imageFolderPath = "C:\images"

# Set the endpoint URL for the CodeProjectAI detection service
$endpointUrl = "http://localhost:32168/v1/vision/detection"

# Get a list of all the image files in the specified folder
$imageFiles = Get-ChildItem $imageFolderPath -Filter *.jpg,*.png

# Iterate through each image file
foreach ($imageFile in $imageFiles) {
  # Read the image file into a byte array
  $imageBytes = [System.IO.File]::ReadAllBytes($imageFile.FullName)

  # Encode the image byte array as base64
  $imageBase64 = [Convert]::ToBase64String($imageBytes)

  # Set the POST body for the detection request
  $requestBody = @{
    image = $imageBase64
    objects = @("human", "vehicle")
  } | ConvertTo-Json

  # Make the POST request to the detection service
  $response = Invoke-RestMethod -Method Post -Uri $endpointUrl -Body $requestBody -ContentType "application/json"

  # Check the response for detected objects
  if ($response.objects) {
    # If objects are detected, send the image to the Telegram group using CURL
    # Replace YOUR_CHAT_ID and YOUR_BOT_TOKEN with the chat ID and bot token for your Telegram group
    $curlCommand = "curl -s -X POST https://api.telegram.org/botYOUR_BOT_TOKEN/sendPhoto -d chat_id=YOUR_CHAT_ID -d photo=`"$($imageFile.FullName)`""
    Invoke-Expression $curlCommand
  }

  # Delete the image file
  Remove-Item $imageFile.FullName
}


modified 11-Jan-23 10:19am.

QuestionLooking for testers Pin
Alberto Enrique Franco Ferreiro24-Nov-22 9:15
Alberto Enrique Franco Ferreiro24-Nov-22 9:15 
AnswerRe: Looking for testers Pin
Richard Deeming24-Nov-22 21:45
mveRichard Deeming24-Nov-22 21:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.