Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

please help!! adding comments to a blog

Posted on 2006-10-19
8
Medium Priority
?
134 Views
Last Modified: 2010-04-25
hi
i am new to php, and i try to build a blog with articles. all that is fine .
now i want to add the ability to write a cemment to an article.
i have problem to write that, and especially the sql code since i understand that it must connect to my users table, article table.
does anyone have a tutorial for that? or explain how to do that?
the problem is with the creation of the recordset and the sql query.

best regards

derrida
0
Comment
Question by:derrida
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
8 Comments
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 17768553
Hi derrida,

You should take some time and explore the DevNet on Adobe's site.  There are some great resources there free for the taking:

http://www.adobe.com/devnet/dreamweaver/articles/php_blog1.html
0
 
LVL 1

Author Comment

by:derrida
ID: 17769376
hi
thanks for the answer.
actually i do use that tutorial but the use some extension from interakt. i need to do it on my own.
i want to learn the process of the php and sql.

so i will be very thankfull if you can explain it to me?

best regards

derrida
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 17770726
I would need to know more about where exactly you are stuck.
0
On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

 
LVL 1

Author Comment

by:derrida
ID: 17772363
hi Jason
i am stuck when i need to create the rsComments with the sql query.
they use the interakt extension, i need to do it alone.
but in teir files they have this qsl :
SELECT blg_comment_com.idart_com, blg_user_usr.username_usr, blg_comment_com.text_com, blg_comment_com.date_com, blg_comment_com.valid_com FROM (blg_comment_com INNER JOIN blg_user_usr ON blg_user_usr.id_usr=blg_comment_com.idusr_com) WHERE blg_comment_com.idart_com=".HTTP_GET_VARS["id_art"]." AND blg_comment_com.valid_com=1 "

so i entered this sql code to the sql section in the rsComments recordset and i get this type of error message:
mysql error: 1064
and they point out that the problem is with the last line:
WHERE blg_comment_com.idart_com=".HTTP_GET_VARS["id_art"]." AND blg_comment_com.valid_com=1 "
and actually i can read and understand most of the code, but not the HTTP part.

can you help me?

best regards

derrida

0
 
LVL 1

Author Comment

by:derrida
ID: 17772385
hi
this is the link to the stage i am stuck in.
http://www.adobe.com/devnet/dreamweaver/articles/php_blog4_08.html

ron
0
 
LVL 70

Accepted Solution

by:
Jason C. Levine earned 750 total points
ID: 17775609
I think it's just a typo...

HTTP_GET_VARS should either be $HTTP_GET_VARS or more simply $_GET
0
 
LVL 1

Author Comment

by:derrida
ID: 17782724
hi jason
thanks, it works. i had the feeling that the problem is there but i knew about $_GET but not about $HTTP_GET_VARS.

ron
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 17782853
Hi ron,

Glad it was a simple fix.

$_GET and all of the "$_" arrays are the superglobals that were introduced in PHP 4.1 (I think it was 4.1).  However, it is possible to turn them off at the config level.  In that case, the older arrays of $HTTP_GET_VARS and $HTTP_POST_VARS are available.

Just make sure that you are using $_ or $HTTP_ consistently throughout your scripts if both work.  They are not equivalent.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Ready to improve network connectivity? Watch this webinar to learn how SD-WANs and a one-click instant connect tool can boost provisions, deployment, and management of your cloud connection.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I still run into .cgi files every now and then. In some instances, I actually prefer the simplicity of a .cgi script to other options. Since I use DreamWeaver extensively, what I needed was a way to open .cgi scripts in Dreamweaver. And I wanted to …
This article is very specific and is only intended to help if you are installing Dreamweaver 8 in a Windows 7 environment with Office 2007 installed.   I'm not sure why Microsoft tends to release OS' that should not be released but they do.  Windows…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question