J.Daniels
-
Posts
143 -
Joined
-
Last visited
Never
Posts posted by J.Daniels
-
-
Now from one of my client I want to share one of the portion of the FTP server. How can I achieve this?
Do you mean you want to share part of the filesystem?
-
If each url is followed by a <br>, you can explode by the <br>, then loop through the array to add it back in with the number:
$linksArray = explode('<br>', $links); $counter = 1; $result = ''; foreach ($linksArray as $l) { $result .= $l . '<br> ' . $counter . ' '; $counter++; }
-
What version of MySQL are you using? Version 5 is picker about the default int definitions.
Try changing tables.sql to this:
# # Table structure for table `groups` # CREATE TABLE `groups` ( `groupid` varchar(10) NOT NULL default '', `gid` int(10) unsigned NOT NULL auto_increment, `members` varchar(255) NOT NULL default '', PRIMARY KEY (`gid`) ) TYPE=InnoDB ; # # Table structure for table `users` # CREATE TABLE `users` ( `id` smallint(2) NOT NULL auto_increment, `userid` varchar(10) NOT NULL default '', `uid` int(10) unsigned NOT NULL default 0, `gid` int(10) unsigned NOT NULL default 0, `passwd` varchar(255) NOT NULL default '', `homedir` varchar(255) NOT NULL default '', `comment` varchar(255) NOT NULL default '', `disabled` int(10) unsigned NOT NULL default '0', `shell` varchar(20) NOT NULL default '/sbin/nologin', `email` varchar(255) NOT NULL default '', `name` varchar(255) NOT NULL default '', `ul_bytes` bigint(20) NOT NULL default 0, `dl_bytes` bigint(20) NOT NULL default 0, `login_count` bigint(20) NOT NULL default 0, `dl_count` bigint(20) NOT NULL default 0, `ul_count` bigint(20) NOT NULL default 0, `last_login` datetime default NULL, PRIMARY KEY (`id`) ) TYPE=InnoDB ;
-
This may be the start of your problem.
<div id="bkOpt"> <table width="720" cellpadding="0" cellspacing="0" border="0"> <tr> <td colspan="2"><h3>Tom/Bass/Kick Drum Options</h3></td> </tr> <tr> <td valign="top" colspan="2" align="left" width="100%" class="r3">Tom/Bass Upgrades</td> </tr> <tr> <td>No Upgrades Chosen</td> </tr> </table> </tr>
You have an opening div, a full table, then a closing </tr>. If I change it to:
<div id="bkOpt"> <table width="720" cellpadding="0" cellspacing="0" border="0"> <tr> <td colspan="2"><h3>Tom/Bass/Kick Drum Options</h3></td> </tr> <tr> <td valign="top" colspan="2" align="left" width="100%" class="r3">Tom/Bass Upgrades</td> </tr> <tr> <td>No Upgrades Chosen</td> </tr> </table> <table>
then it works as expected.
Try validating your code through the W3C validator.
-
To create another FULLTEXT index, run this in phpmyadmin:
CREATE FULLTEXT INDEX newIndex ON affiliSt_products1 (prodName,prodBrand,prodCategory);
-
The problem with your switch statement is that if complexfunction() is false, do y; won't execute.
if ($a && complexandtimeconsumingfunction()) { do x; } else { do y; }
This will work because if $a is false, it will not continue with the second part of the conditional.
-
Check out strpos() which will return the position of the first occurrence or -1 if it doesn't exist.
-
You can use any block type elements including all the ones listed in the error or the fieldset / legend elements.
-
Apparently, forms are block elements, but can only contain block level children. I'm not sure how reliable this is, but i got it from here: http://dorward.me.uk/www/element-not-allowed/
-
It was my mistake. The MATCH function must match a FULLTEXT index. To create a new index see the MySQL Reference Manual
-
So you're saying stick that code within the conditional statements for each item and echo $totalcost after the loop?
You were saying that you couldn't use the SUM statement in your SQL query. As you loop through your result set and determine that a value needs to be added to the total, add it to a variable holding the total.
-
+randomize the name of the field, store it in the session so that it's harder to scrape (source code)
This is similar to what xtopolis said, You can create a generated token from the form page, and pass it in a hidden field to the processing page. This will at least disable any outside form from submitting. If the page is loaded then scraped, it's difficult to determine whether it was loaded by a human or script without some type of captcha.
-
If you don't want to search the product description, I believe you just need to take it out of the MATCH function:
if ($indcount == 0) { $sql = "SELECT *, ( (1.3 * (MATCH(prodName) AGAINST (".quote_smart($pluspieces)." IN BOOLEAN MODE))) + (0.6 * (MATCH(merchant,prodCategory,prodBrand) AGAINST (".quote_smart($pluspieces)." IN BOOLEAN MODE))) ) AS relevance FROM affiliSt_products1 WHERE ( MATCH(prodName,merchant,prodCategory,prodBrand) AGAINST (".quote_smart($pluspieces)." IN BOOLEAN MODE) ) HAVING relevance > 0 AND dbProdID != '".$pDetails['dbProdID']."' ORDER BY relevance DESC LIMIT 0, ".$maxRows_product.""; } else { $sql = "SELECT * FROM affiliSt_products1 WHERE MATCH (prodName,prodBrand,prodCategory) AGAINST (".quote_smart($pluspieces).") AND dbProdID != '".$pDetails['dbProdID']."' LIMIT 0, ".$maxRows_product.""; }
-
Have you tested that statement? The syntax looks correct, however, your conditionals would return anything outside of the date range you specified.
-
In the function definition, you are specifying that it return by reference:
public static function & gvar($i) {
This is from Passing By References in the PHP manual
-
PHP is actually executing the command. The problem lies with the iptables setup. If you control the server here is something that I found that may help:
If you are hosted, you'll have to contact your host.
-
Maybe I'm not understanding the question correctly, but you should be able to hold the total cost in a variable:
$totalCost = 0; while (<loop through db results>) { if (<condition>) { $totalCost += $cost; } }
-
It may be because of the parent nav container, since the width is set to 125px.
When I moved the "salad" container above:
<div id="wrapper"> <div id="salad"> <div id="lettuce"> </div> <div class="content">Tip of the day: This will not contain tips of the day.</div> </div> <div id="nav"> <div id="logo"></div> ...
it appears to render the way you want.
-
top may need to be in quotes:
<TD valign="top">
-
If it is the same version of IE on each computer, there may be some personal settings that are different. For example, the color of links.
-
RewriteCond %{REQUEST_FILENAME} !-d
does not apply the rewrite rule if the directory exists.
-
It is because of this part of the code:
if ($decimal > 2147483647) { $decimal -= 4294967296; }
The number I get right before this is 3573956936
-
In Seamonkey, everything appears to be working as you stated.
It would help if stated what browser you built against, and what browser is causing problems.
-
The directories would have to be owned by the apache process to lower the permissions. If you can't change the owner, a more secure way would be to store the directory outside of the DocumentRoot tree, and use PHP to read in the images.
If you only have access through FTP, a quick google search for recursive chmod ftp client shows that FileZilla supports it. I don't have any experience with how well it works though.
[SOLVED] back button/ recaptcha
in MySQL Help
Posted
You can also just send a no cache header on your login page. This will cause the page to refresh every time it is visited.
Taken from the PHP Manual