PHP technical question

Status
Not open for further replies.

idlehands

New Member
Messages
16
Reaction score
0
Points
0
Hi all,

I'm trying to implement some PHP code for a comments system on my site.

I've set it all up properly and I'm at the implementation stage.

According to the readme I have for the script, I have this to do:

How to use

"To show the comments on a page copy and paste the following code:

If your site uses php:

<?php require("/path/to/your/www-home/comments/comments.php"); ?>

OR

<?php virtual("/comments/comments.php"); ?>

(could not work with some php versions) "

Now, I use nvu as an authoring tool and I know how to insert PHP code, but what I was wondering is what I should put in the 'path/to/your/www-home/' bit.

I have the comments folder in the public_html folder of my site.

Hope someone can help!

Thanks

Rob
 
Last edited:

TomyVk

Member
Messages
179
Reaction score
0
Points
16
Hmm, on bb2 it works fine, but i don't know for the bb3 version
 

SyncViews

New Member
Messages
37
Reaction score
0
Points
0
(presuming it's in public_html/comments/comments.php and your page is in public_html)
<?php require("./comments/comments.php"); ?>

You could use the eact url for the file but I think x10 has disabled includes over urls?
 

idlehands

New Member
Messages
16
Reaction score
0
Points
0
It's really odd actually, it seems no matter what I try no PHP script will execute on the site

If i navigate directly to http://MYDOMAIN.x10hosting.com/comments/comments.php then the comments box/system works fine, but I'd rather have it embedded under an article so folks can comment.

Is there any way to do that does anybody know?
 
Last edited:

SyncViews

New Member
Messages
37
Reaction score
0
Points
0
post your script (the one where you want the comment box to appear). give it's file location so I can see if you have the path wrong.
 

idlehands

New Member
Messages
16
Reaction score
0
Points
0
It's ok - I had the ending of the address as .html - so of course it wasn't working.

Changed to .php and it's working fine.

D'Oh!

Thanks guys!
 
Status
Not open for further replies.
Top