GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   Any PHP/MySQL Guys Up? (https://gfy.com/showthread.php?t=621291)

Bama 06-13-2006 11:13 PM

Any PHP/MySQL Guys Up?
 
I usually have my guy do this stuff but he's on vaca and I'd like to get this done so I can move forward so if anyone that knows php/sql, do me a favor and take a quick peek for me...

This calls the output for an events script I'm using and I'd like to be able to truncate the title ($result) to 10 characters (some titles are way too long for the section this output is echo'd)

Thanks in advance!

http://www.bamas.com/code.txt

darksoul 06-13-2006 11:21 PM

find
Code:

while($row = mysql_fetch_row($result)){
and add
Code:

$row[1] = substr($row[1],0,10);
so your code will look like:
Code:

while($row = mysql_fetch_row($result)){
$row[1] = substr($row[1],0,10);
.
.
.


Bama 06-13-2006 11:45 PM

Thank you Dark Soul - that worked like a charm!


All times are GMT -7. The time now is 02:38 AM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123