
unrelenting
Members-
Posts
161 -
Joined
-
Last visited
Never
Everything posted by unrelenting
-
Wow. You are pure genius. It's akin to witchcraft how you guys can make things happen. Thanks.
-
You understood my request perfectly. I will give that a whirl this evening when I get home from work. I appreciate your time. I am using the same forum software that phpfreaks uses (SMF) and they have that _blank attribute built into it already so that is really out of my control.
-
It's really not that bad and is quite easy after some practice. I can move this to the Regex board if you'd like. I know they are always hungry for a new challenge there. Please do. Thanks.
-
I figured that is what I would need but was hoping for a different approach. Regex is the most complicated thing I have seen in PHP.
-
I am trying to modify my message board posts in a way that it will display any <img> images that are located in my smileys folder but only display a <a href> link if they are located anywhere else. So if someone makes a post using a smiley located in http://mysite/forum/smileys folder then it makes no change at all because it will already be in the <img> tags. But if it is a hotlink to an image on another site or even a hotlink to an image in a different folder on my own site I'd like to change it from: <img src="http://differentsite.com/image.jpg" alt="" border="0" /> to: <a href="http://differentsite.com/image.jpg" target="_blank">http://differentsite.com/image.jpg</a> The entire post is stored in the $message variable. How would I code this to search the variable for instances of <img> tag links and ignore it if it is in the http://mysite/forum/smileys folder but change it to an <a href> link if it points to any other folder or website? Thanks.
-
Need some guidance for creating a WAP page
unrelenting replied to unrelenting's topic in PHP Coding Help
But I need to know how to identify a cellular user to direct them there in the event that they just punched in the http://gmail.com address. -
Need some guidance for creating a WAP page
unrelenting replied to unrelenting's topic in PHP Coding Help
There are still lots of people who pay-per-kilobyte out there, rather than subscribing to unlimited internet packages, that don't want to pay extra money for a site that is heavy on graphics. I am one of them. -
I would like to setup a page just for cellular viewers but I can't figure out how to identify a cellular viewer to point them to the new page. Is there just a simple PHP if statement or something I should use or how is this normally done?
-
Try trim($user);
-
Are you absolutely sure that there is a row in the Member table with the loginName = to $user?
-
Try: $query = "SELECT * FROM Member WHERE loginName='".$user."'";
-
Glad you got it working.
-
<?php include "base.php"; $_SESSION = array(); session_destroy(); ?> <meta http-equiv="refresh" content="0";"index.php">
-
I don't know about 'best' but you can do it with file_get_contents or cURL.
-
[SOLVED] Encrypt info and decrypt with a users key.
unrelenting replied to iarp's topic in PHP Coding Help
Read into these... http://dev.mysql.com/doc/refman/5.1/en/encryption-functions.html -
Try something like this. <? // database connection info if ((isset ($_GET['currentpage'])) { $currentpage = $_GET('currentpage'); $conn = mysql_connect("80.94.196.33","USER_INFO") or trigger_error("SQL", E_USER_ERROR); $db = mysql_select_db('bssql',$conn) or trigger_error("SQL", E_USER_ERROR); $result = mysql_query ('SELECT title, subtitle, article FROM articles WHERE title = "' . $title . '"'); while(list($title, $subtitle, $article) = mysql_fetch_row($result)) { echo $title; echo "<BR />"; echo $subtitle; echo "<BR />"; echo nl2br($article); echo "<BR />"; } } $conn = mysql_connect("80.94.196.33","USER_INFO") or trigger_error("SQL", E_USER_ERROR); $db = mysql_select_db('bssql',$conn) or trigger_error("SQL", E_USER_ERROR); $result = mysql_query ("SELECT title, subtitle, article FROM articles ORDER BY ID DESC"); while(list($title, $subtitle, $article) = mysql_fetch_row($result)) { echo " <a href='{$_SERVER['PHP_SELF']}?currentpage=$title'>$title</a><BR />"; echo $subtitle; echo "<BR />"; echo "<BR />"; } else { echo "ERROR"; } ?>
-
You probably need to have data for every column in your csv file. Something like: 1, 1, 1, Bob, 345275 2, 2, 2, Tim, 2547354 3, 3, 3, Test, 5763 Or just make the table with only 2 columns, import the csv file and then go back in and add the other columns.
-
http://www.tizag.com/phpT/postget.php
-
Also, make sure that $def_path is equal to /home/content/f/a/b/XXXX/html I added this line to the top of your script and it moved the file correctly (using my own filepath, of course): $def_path = "/home/content/f/a/b/XXXX/html";
-
That means you have to enter the location like this: /home/content/f/a/b/fabis94/ The script is checking for a forward slash before and after the inputted location. If it doesn't have that then it gives you that error.
-
Indeed.
-
-
datetime to be outputted as selected in a date selection list
unrelenting replied to dadamssg's topic in PHP Coding Help
Try this: <?php /* build selection list for the month */ $todayMO = $mo; //get the month selected echo "<select name='smonth'>\n"; for ($n=1;$n<=12;$n++) { if ($todayMO == $n) { echo '<option value=" . $n . " selected>' . $smonth[$n] . '</select>'; } else { echo '<option value=" . $n . ">' . $smonth[$n] . '</select>\n'; } } ?> -
text form data to mysql depending on input and user ?
unrelenting replied to crazzypappy's topic in PHP Coding Help
I like that best. -
text form data to mysql depending on input and user ?
unrelenting replied to crazzypappy's topic in PHP Coding Help
$whitelist = array("word1", "word2", "word3"); if (in_array($input, $whitelist)) { }