Update link pictures and Insert new item

  • nole52

    14 messaggi

    Francia

    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 messaggi

    Francia

    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
    Conto chiuso

    348 messaggi

    Belgio

    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...
    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 messaggi

    Francia

    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
    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 messaggi

    Francia

    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 messaggi

    Francia

    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

    11 messaggi

    Kazakistan

    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

    11 messaggi

    Kazakistan

    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 messaggi

    Francia

    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

    11 messaggi

    Kazakistan

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

    348 messaggi

    Belgio

    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 messaggi

    Francia

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

    0 messaggi

    Belgio

    It do not work anymore today... i dont know why again, but my pictures are not more uploaded.
    Le informazioni non sono più disponibili perché l'account di questo utente è stato eliminato (Regolamento RGPD).

Unisciti alla community di collezionisti!

Registrati Login