User Profile
Collapse
-
That bit does not work, it does not parse the variables any more in the url and it still puts the 'more' link on all of the comments even if they have less than 97 characters :(... -
Ahh thanks for that, Why would the thing that ronald gave me take all the text away because if i am reading it right it is just doing the same as mine just a little earlier, I am very, very new to this though so i am probably on completely the wrong track :)
(i did feel proud that i managed to get it to do what i wanted though).
So would your thingy be better than mine as i will use yours if it is for the length of comments....Leave a comment:
-
Hello again :)
I fixed it using thisI had to put the first number to 0 or it got rid of the first letter :) and the comment looked a little odd lol....Code:$row[comment] = substr("$row[comment]",0,97);
One more thing if i may. How would i go about telling it to putafter $row[comment]...Code: <a href="http://www.thatsshocking.com/photo/data/$row[cat]/thumbs/$bigimage">More</a>
Leave a comment:
-
Hi,
I used that and it seems to take all of the text away?
Thanks for the help though :)Leave a comment:
-
hi me again, How do I limit the amount of chars i get from a query.
Hi,
How do I limit the amount of charcters in a query result.
the $row[comment] result is sometimes very big and I only want to get the first 100 or so characters.Code:$result = mysql_query("SELECT username,cat,comment,photo,userid,rating,date
Thanks very much
syb. -
-
How do i strip the extension from a query result.
Hi,
I am trying to strip the extension from the result of a query so i can then use what is left for something else.
What i would like is if the result of the query is MOV123.avi i need to take away the .avi bit and replace it with .jpg, Is this possible please. -
sybaris replied to How do i join 2 querys and use the result from one to disallow part of the other.in PHPhi,
This is what is underneath that bit....Code:$cmpscomms .= <<<PPPRINT <tr> <td class="$bgclass" align="left"> <span class="{$Style['small']}">$row[comment]<br>by <a href="http://www.thatsshocking.com/member.php?u=$row[userid]">$row[username]</a> </td> <td class="$bgclass"><aLeave a comment:
-
sybaris replied to How do i join 2 querys and use the result from one to disallow part of the other.in PHPThanks very much would you like to come for christmas dinner now :).
One more thing if you dont mind.
i useCode:if (!empty($row[comment]))
to stop it showing any comments without any actual words in (if you rate a photo it puts a blank comment in) the thing is it only has 4 comments then (if one is blank) is there a way to get the query to look for a blank one ignore it and get the next one?
...Leave a comment:
-
sybaris replied to How do i join 2 querys and use the result from one to disallow part of the other.in PHPHi,
No it is only 508 and 512 I want to disallow, although I now find that i need to get rid of any comments that are blank lol.
thanks
sybLeave a comment:
-
sybaris started a topic How do i join 2 querys and use the result from one to disallow part of the other.in PHPHow do i join 2 querys and use the result from one to disallow part of the other.
I am using this [PHP]$result = mysql_query("SE LECT username,cat,co mment,photo,use rid FROM pp_comments ORDER BY date desc LIMIT 5" ) or die(mysql_error ());[/PHP] to get the results i want but i want to disallow certain catagorys, I can get the catagory ids from the catagory table but how would i tell the first query not to use certain ones from it, like cat no 508 and 512,
Thanks
sybaris
p.s...
No activity results to display
Show More
Leave a comment: