Update link pictures and Insert new item

  • nole52

    14 berichten

    Frankrijk

    I have some cards with no pictures because i haven't upload these on my server, so i make a code to update the cards with the pictures after upload but i see no change.

    Moreover, i tried to add new cards and the delcampe server said ok, but i can't see them on my shop.

    Can you say me why?

    I use rest API, and when i upload new cards one or two hours before it worked but now no.
  • nole52

    14 berichten

    Frankrijk

    OK, the insert of item is ok, it take long time but it work... i think the servers are long.

    But i can't have the pictures, it not download it, so i have lot of item without pictures.

    So i tried to update image links but nothing happen, but the script say me it's ok...
  • @thomas
    Beheerder

    348 berichten

    België

    OK, the insert of item is ok, it take long time but it work... i think the servers are long.

    But i can't have the pictures, it not download it, so i have lot of item without pictures.

    So i tried to update image links but nothing happen, but the script say me it's ok...
    • Aangemaakt 19 nov 2020 op 17:53
    • #1213198
    Hello nole52,

    I tested the api on my side and did not encounter any problem to update images.

    Which host do you use to store your images?
    Can you give me an example of a call you made to update an item?

    Also note that any insertion or update of an item may take some time.

    Best Regards,
    --
    Thomas
    Delcampe Team
  • nole52

    14 berichten

    Frankrijk

    Hello nole52,

    I tested the api on my side and did not encounter any problem to update images.

    Which host do you use to store your images?
    Can you give me an example of a call you made to update an item?

    Also note that any insertion or update of an item may take some time.

    Best Regards,
    --
    Thomas
    Delcampe Team
    • Aangemaakt 20 nov 2020 op 08:40
    • #1213465
    I use easy-hebergement.

    Here my code example :

    // IMAGES A UPDATE
    $postData = array(
    'item' => array(
    'images' => array(
    '.$url1.',
    '.$url2.'
    )
    )
    );


    //met à jour les images
    //RESOURCE CALL WITH PUT METHOD
    $url = ' Link (https) ;
    $ch = curl_init();
    curl_setopt ($ch, CURLOPT_URL, $url);
    curl_setopt ($ch, CURLOPT_POSTFIELDS, http_build_query($postData) );
    curl_setopt ($ch, CURLOPT_CUSTOMREQUEST, "PUT");
    curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, true);
    curl_setopt ($ch, CURLOPT_RETURNTRANSFER, true);
    $xml_response = curl_exec($ch);


    $dom = new \DOMDocument();
    $dom->loadXML($xml_response);
    $statusresult = $dom->getElementsByTagName( "status" )->item(0)->nodeValue;

    //si l'item renvoi un résultat cest ok
    if($dom->getElementsByTagName( "status" )->length > 0)
    {
    echo "Update ok <br />";
    }
    else
    {
    echo "Erreur dans l'update : ".$dom->getElementsByTagName( "error" )->item(0)->nodeValue." <br />";
    }



    Each update say me it's ok
  • nole52

    14 berichten

    Frankrijk

    Ok, i tried the upload with my old website and it work... but i suspect that my new don't work because my new web adress is like : http : // mywebsite.cluster3.easy-hebergement.net/images/myimage.jpg

    Perhaps it's don't want to work because of the multiple "." for the adress or the "-" ?

    When i tried directly the adress of my image it work, so it's perhaps your server who don't want accept it?
  • nole52

    14 berichten

    Frankrijk

    It's not good at all... with my old website it not upload all the images too... i have some item who good upload but some other are not uploaded and i don't know why... but the links of the images in my website are good.

    Can you help me and say me why it doesn't work good?
  • elenashvarts
    Rekening afgesloten
    PRO free

    11 berichten

    Kazachstan

    Alas, I also get problems loading images. It started two weeks ago.
    Since then, 10% of the images have not been uploaded.
    My hosting hasn't changed, everything worked well before.
  • elenashvarts
    Rekening afgesloten
    PRO free

    11 berichten

    Kazachstan

    Hello.
    Do members of the gold club receive priority service?
    We asked questions - but the problem is still not resolved. 10% of my lots do not have an image.
  • nole52

    14 berichten

    Frankrijk

    My problem is solved now, i have no change my code, so i think it was the delcampe servers who had problems, but it work good for me now.

    I hope it will continue ^^
  • elenashvarts
    Rekening afgesloten
    PRO free

    11 berichten

    Kazachstan

    Alas, my problem is not being solved. Images still load poorly.
  • @thomas
    Beheerder

    348 berichten

    België

    Hello elenashvarts,

    We do not encounter any problems loading the images to our knowledge. Some hosts limit the flow of servers they do not know. Can you provide us with the url of an image that has not been loaded?

    Best Regards,
    --
    Thomas
    Delcampe Team
  • nole52

    14 berichten

    Frankrijk

    It do not work anymore today... i dont know why again, but my pictures are not more uploaded.
  • Rekening verwijderd
    Rekening verwijderd

    0 berichten

    België

    It do not work anymore today... i dont know why again, but my pictures are not more uploaded.
    • Aangemaakt 7 dec 2020 op 20:29
    • #1221101
    De informatie is niet meer beschikbaar omdat de rekening van deze gebruiker is verwijderd (AVG)

Word lid van de verzamelaars-community!

Registreren Aanmelden