PHP - Using Disqus For Ones Own Website With Php?
I just signed up on Disqus.
Link: https://disqus.com/
My Question:
Can this commenting system only be used for those platfroms which one can choose?
I was looking to use this for my own web application (in PHP).
If this may not work with Disqus, is there something similar to Disqus out there, quick and easy to set up?
Similar TutorialsThis topic has been moved to PHP Applications. http://www.phpfreaks.com/forums/index.php?topic=358814.0 I want to add comments to my website, which is built in php. I am planning on using http://www.disqus.com/ coz i want to be able to backup my comments . I used http://www.htmlcommentbox.com/ before and put the code in a php file and inserted this php code <?php include("includes/comment.php"); ?> , to where i want comments to be displayed in my web pages. But for Disqus I must use a unique id number or url with the Disqus code for each page on my website. I want to use the same code for all pages. Can i use this code Code: [Select] <?php $currentFile = $_SERVER["PHP_SELF"]; $parts = Explode('/', $currentFile); echo $parts[count($parts) - 1]; ?>OR THIS (results seem the same, in the my example at the bottom of this, i used the code below) Code: [Select] <?php echo basename ( $_SERVER['PHP_SELF'] ) ; ?> Here is the Disqus code in which i want to insert the above php. Code: [Select] <div id="disqus_thread"></div> <script type="text/javascript"> /* * * CONFIGURATION VARIABLES: EDIT BEFORE PASTING INTO YOUR WEBPAGE * * */ var disqus_shortname = 'example'; // required: replace example with your forum shortname // The following are highly recommended additional parameters. Remove the slashes in front to use. // var disqus_identifier = 'unique_dynamic_id_1234'; // var disqus_url = 'http://example.com/permalink-to-page.html'; /* * * DON'T EDIT BELOW THIS LINE * * */ (function() { var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true; dsq.src = 'http://' + disqus_shortname + '.disqus.com/embed.js'; (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq); })(); </script> <noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript> <a href="http://disqus.com" class="dsq-brlink">blog comments powered by <span class="logo-disqus">Disqus</span></a> And this is the Disqus code after i inserted the php. Code: [Select] <div id="disqus_thread"></div> <script type="text/javascript"> /* * * CONFIGURATION VARIABLES: EDIT BEFORE PASTING INTO YOUR WEBPAGE * * */ var disqus_shortname = 'example'; // required: replace example with your forum shortname // The following are highly recommended additional parameters. Remove the slashes in front to use. // var disqus_identifier = 'unique_dynamic_id_1234'; // var disqus_url = '<?php echo basename ( $_SERVER['PHP_SELF'] ) ;?>'; /* * * DON'T EDIT BELOW THIS LINE * * */ (function() { var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true; dsq.src = 'http://' + disqus_shortname + '.disqus.com/embed.js'; (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq); })(); </script> <noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript> <a href="http://disqus.com" class="dsq-brlink">blog comments powered by <span class="logo-disqus">Disqus</span></a> Do you think this will work or is there a better method. I have used the php code on a test php page and the result was index.php . How can i just get index as the result. How this is explained ok. Thanks for taking the time to read this I'm trying to make a League of Legends (a video game) community website, both as a personal project and for practice. Now the game has a lot of champions, each of whom have 5 unique abilities. Now, I thought about manually inputting all the details about each champion into a MySQL database, but that would long and tedious, and I don't really have the time for it now. Also, the game patches very oftern (like, once every 2 weeks) which changes many of the stats, etc. of the champion, and it is not possible for me to keep manually updating these every time there is a patch. Fortunately, there is a League of Legends Wiki which has all the data I need in their specific champion pages, which they keep updated per patch. So I was wondering if there was any way to get the data from the divs in the wiki, and have it display on my site. What I want to do in my website is that whenever someone types a champion's name (in a post or whatever), I want it to display a hover-over dialog with some of the champions details. And a lot of other features such as that. In plain English I need a way to : > Tell PHP to go to the wiki's source code on a specific page > Find a specific div container > Get X data from there > Pass X data into a function to display the hover-over I think this way, I would not have to maintain a database as I can leech off the wiki's data. I have not coded anything like this before, so I would like a few pointers as to how to achieve this. Any help will be appreciated! I tried searching on google but couldn't find any relevant information, please redirect me to relevant source or help me with the code. I want to pass a domain name in text field which will be scanned and then the script will display entire site map. Not external links or links on a page. Sorry it is not easy for me to explain. Eg. if i pass abc.com Script will display abc.com/12/adn.php abc.com/asd/asd/ etc Whatever their url format is. All the links on that domain. hello My database is in a same server with seperate domain name , then I want to insert from website1 mysql data on website2 mysql data. can anyone help me? Is it possible to download files from a website to my online websites root directory? reason I'm asking is because I have been downloading large video files to my computer which take about 20 minutes!! Then I use FTP to upload them to my site but it takes about 2-3 hours per video!! I was looking for a faster way! All help would be great! Hello everybody!
I have been asked by a customer to develop a GTP website (Get To Pay, those websites where people earn money from clicking on ads). I managed to write the backend, signup and login but I am unsure how the ads part, with built-in user-tracking works and fallback link works.
I would really appreciate any kind of help.
Thank you very much!
P.S. For the user tracking I was thinking of sessions with matching ip and user agents together with an anti-proxy online service (e.g. MaxMind, Proxystop, ...)
This would be an example of a page I'm referring to: http://www.curse.com...other-downloads
I want to get the file name and compare it to another name (to see if they are the same or not). I have no idea how to access that page from my website. I'm guessing PHP would be best although if you don't think so tell me what you think would be better (I was thinking javascript but don't think that's cross-site compatible). Is there a PHP function to get the value of the href which is in this case (as of this posting) "Railcraft 9.4.0.0".
I used inspect element to see the code of the page but have no idea if this is possible or if I'm even going about this the right way. The code would have to work on this entire website (all pages have the smae layout as this one though! Any help is greatly appreciated!
Hi, I haven't used any php for a while, but i am making a website, and i need some advice on how to do the following: I want the website to change an image once every 24 hours, the image will revert back to the original image after 2 minutes. Does anyone have an idea how I could start doing this? My code on website is not validate on W3 Validator.
<?xml version="1.0" encoding="ISO-8859-1"?> Hi there Can anyone please help me. I am trying to get my website working but i am struggling big time with the php. The things i need to do are not to complicated however my lack of skill with php is making me struggle. I need help in making the php work on my website. Can anyone help please. (Please note it is not a commercial or business website.) Anyone who can help please contact me. Thanks I am working on a website and I am at a standstill. I would rather speak to someone one on one but its been very difficult to find someone that could help. I have the scripts that I want but when I add the scripts to the mainpage everything stops working. I really don't want to go to wordpress because I am almost done with this one. Thanks.
Hello everyone and thank you for reading this.
My goal: Build a site like sportingnewschicago.com
What it does? It has different sectiions of different teams. Then it displays the tittle of the news and makes them be able to click on to go to the news site. The site some how checks a list of sites and post them on their respected section. But only ones that have not already been listed.
What i want to do? Well i want to try to learn how to do this. Is this something i can make with the help of members here? It would only have index.php and thats it.
Please let me know if anyone would be interested in teaching me as i do it. If not i would understand. Thank you.
I was not expecting this but when I managed to connect to a chatroom and close out firefox.... The user stayed in the chatroom. This user should of pinged out by now but it's staying online. How do I end this connection? So far I turned off my internet, and blocked all access to the site. Hi there, This forum has been helpful to me so far. I'd like to thank you for your help. Now the question is, we will be using xe.com services for our shopping cart and prices. Based to the customer's location the currency must change. For example, if the customer is sitting in Europe, the currency for the product and the shopping cart will be displayed in Euros, similarly for the US customers it will be in USD. I would like to know how we can do this using xe.com and what steps are required. Any comments/feedbacks are always welcome! Thank you! Hi,i m confused php developer (beginner bt i wnt to do advance things with php and mysql) i want to make video website for myself and i also have 10000s of video in my pc and can any one help me to complete this project 1. when user clik on some video thumbnail the video player(jw or flow player) pop-up and start the video without go to different page(if possible) 2.do i need to upload all my video first to my server or i upload it with php mysql then how is it possible to link and make thumbnail of all the 10000s videos with video player so all the video will play without error and i knw i cant make these 10000s videos thumbnails and video link and pages for each videos so how can i start my thing please help me in this a BIG THANKS in advance hey guys!, im finding it difficult to do my miniproj on "alumni websit" can you help me out? features: 1)first page is the login/register page where we can login as a admin or a member 1.1)logged in as a member we should have features like sending messages to other members we should be able to post in open forum see in the second step when we post in the forum, the admin will hav to approve whether to post it or not(basing on the adult content) 1.2)logged in as a admin he should be able to remove users,approve messages How would I show the PHP code on the website page? I'm not sure if this should be under PHP or HTML or what, but, like on the forums where you see the <?php echo 'sdfjksdf'; ?> etc. How do I make it so I can write PHP on the website? Hey guys im looking at doing a project that involves sending SMS(Text Message) from an online website. Im just wondering how hard it is to setup using php? For example: If i have registered user (manager) and i want to send a SMS to my team mates from the website itself, how hard would this be? Hi, I have a requirement of making the single website for different locations, customer running a enterprise, and he wants me to show corresponding items for corresponding locations(nearly around 30 locations) I am very confused how to make this(making separate sub domains for separate location), pls help me regarding this. Thanks, |