Jump to content

gdfhghjdfghgfhf

Members
  • Posts

    218
  • Joined

  • Last visited

Profile Information

  • Gender
    Not Telling

gdfhghjdfghgfhf's Achievements

Regular Member

Regular Member (3/5)

0

Reputation

  1. Please delete my account and all messages posted on the forum. Bye.
  2. What a waste of time, i came here just to get a link to a manual i've already read, with no other additional informations. This forum is useless, back to Stack Overflow. You can delete my account here.
  3. Can you elaborate ? Just linking the manual with so many different parameters isn't helping me CURLOPT_HTTPHEADER An array of HTTP header fields to set, in the format array('Content-type: text/plain', 'Content-length: 100') So my problem is that i didn't set the content-length ? Or i don't need the "ACCEPT" Part ? Or is it something else ?
  4. i looked everywhere but couldnt find a solution... how do i parse discogs bbcode and convert it to html, or just strip it out ? api is returning band biographys with lot of non-standard bbcode and discogs internal link... how can i parse it to human-readable text ready to be displayed to end user on my website ? i asked in discogs forum and got this answer: If you don't want that specific format, you can include an Accept header in your response with your preferred response type. We currently offer Discogs format (what you've got now), plaintext (URLs and other formatting is just stripped away), and HTML. For more information, see the API docs: https://www.discogs.com/developers/#page:home,header:home-versioning-and-media-types So i tried this but it didn't work: curl_setopt($ch, CURLOPT_HTTPHEADER, array('application/vnd.discogs.v2.html+json')); here's what i have so far $ch = curl_init(); //initialize the session curl_setopt($ch, CURLOPT_USERAGENT, 'APN/1.0 +https://www.anarcho-punk.net'); //Set the User-Agent Identifier curl_setopt($ch, CURLOPT_URL, $discogs_label_apiurl); //Set the URL of the page or file to download. curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); //Ask cURL to return the contents in a variable instead of simply echoing them //curl_setopt($ch, CURLOPT_HTTPHEADER, array('application/vnd.discogs.v2.html+json')); // curl_setopt($ch, CURLOPT_HTTPHEADER, array('ACCEPT' => 'application/vnd.discogs.v2.html+json')); curl_setopt($ch, CURLOPT_HTTPHEADER, array('ACCEPT' => 'text/html')); $output = curl_exec($ch);
  5. So this is probably the problem. I need to set UTF-8 in the left menu of my site. So if i put the header() call inside my left menu script, it will not be the very first thing in the file when index.php loads Even if i put the code in the first line of "last2.php", i get this error: so i have tryed to put the PHP code inside the beginning of "overall_header.html" but it doesn't change anything
  6. if i put it in "last2.php" menu it will write an error message saying the header has already been sent So i replaced the current charset with your code in phpbb header's template..... But i still have the same problem
  7. i already tryed that, just tryed again and it doesnt change anything see by yourself: http://www.anarcho-punk.net/ this is the script where the problem comes from (i include() this menu on the front page) http://www.anarcho-punk.net/last2.php As you can see the russian topic name is written "????????" but when you click on the link, everything is good: http://www.anarcho-punk.net/viewtopic.php?f=5&t=1981
  8. I have a weird problem related to characters encoding on my website I have using a phpbb3 forum, and i have a french and russian forum. I have built a menu showing the last posts of all forums My problem is that when a post title includes weird character (french characters like "é à â î Ç" or russian characters) it will display incorrectly I don't understand why, because the characters are displayed correctly inside the forums What do i have to do?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.