Posts
 
Reputation
Joined
Last Seen
Ranked #1K
Strength to Increase Rep
+6
Strength to Decrease Rep
-1
73% Quality Score
Upvotes Received
5
Posts with Upvotes
5
Upvoting Members
5
Downvotes Received
2
Posts with Downvotes
2
Downvoting Members
2
2 Commented Posts
~19.3K People Reached
About Me

Im a Web Developer. I like be to be nerdy, play soccer and eat cookies.

Interests
php, web development, apache, mysql, wordpress, ajax, soccer, hockey
PC Specs
3 desktops, 3 laptops, 1 netbook, 1 ipod touch, 1 smartphone and a lot of spare parts. I am a fan of…
Favorite Tags
Member Avatar for martinkorner

[QUOTE=martinkorner;989143]Hi, I am trying to write a .htaccess script that can redirect any URL on my site (whether it exists or not, including sub-domains) to the index page of that site. For example: example.com/pages/page.htm ---> example.com sub.example.com/page.htm ---> example.com error.example.com/error ---> example.com I've tried a few things with mod_rewrite but …

Member Avatar for guruparthi
0
1K
Member Avatar for happygeek

I also have a few sites that increased due to this change... however, I'll admit some of my pages are ranked above others much better sites. Not all my sites increased rank, most of them had no shift.

Member Avatar for iamseo
7
3K
Member Avatar for mls880

Looks to me like you've got WHERE in there twice. An SQL statement should only have 1. (unless your using join, subqueries, etc.) I havent tested this but try: [CODE] UPDATE `isc_products` WHERE `prodcostprice` >= 0 AND `prodcostprice` <= 1000 SET `prodprice` = (`prodcostprice` * 1.20); [/CODE] notice, I removed …

Member Avatar for AndyVI
0
198
Member Avatar for CFROG

If you put the pictures into an list <li> it would be easier to keep updated. You could style them to show 5 pictures per row. Then later, if you need 3 pictures per row, you can just adjust your css, rather than your entire table structure. But if you …

Member Avatar for ijn1
0
282
Member Avatar for Lanor
Member Avatar for kylegetson

looking to build a network for link exchange/promotion. The plan is to get a distributed group of reliable people. Then exchange promotion between group members. The group would need to be relatively small and manage-able. Communication would need to be open amongst the group, but kept private and away from …

Member Avatar for joelchrist
0
176
Member Avatar for eswar.aspire

the .htaccess file won't be read by apache outside the document root. if your just trying to restrict access, you could use authentication, not sure if you could get flash to work with that though. generally, you put something outside the document root that you don't want the web to …

Member Avatar for eswar.aspire
0
997
Member Avatar for Rambomst

if CPU and RAM usage isnt high when the page is 'loading' seems to me that the problem is elsewhere. Do pages load successfully, or do they timeout? Most browsers have a 90sec timeout by default. Is the server responding with a static file or a dynamic script? Check to …

Member Avatar for Rambomst
0
144
Member Avatar for JayGeePee

You could leave it as an html file, and make your html files parsable as php files (with addhandler in your .htaccess) I would stay away form iframes wherever possible.

Member Avatar for kylegetson
0
196
Member Avatar for sakush100

Use this, you won't have to type up the months. This creates a string '5/1/2010' and then converts it to a timestamp, and passes it into the date function with the 'F' as the format, which will output the text version of the month. [CODE] $oldm = 5; $newm = …

Member Avatar for kylegetson
0
104
Member Avatar for cdes1145

the counter.txt file does not exist. create the file first, and make sure its writable by the webserver.

Member Avatar for kylegetson
0
720
Member Avatar for mayuri_desh

use mktime() or strtotime(). [CODE] strtotime('April 1 ' . date(Y) . ' 1:59:59'); [/CODE] this would get you paril 1 of the current year at 1:59:59.

Member Avatar for P0lT10n
0
82
Member Avatar for emillion82

there are a few ways to do it use explode() to split by a comma and space, strpos() to find the position of of the period, and substr() to only get the data after that position. or, you can use regular expresions and preg_replace(), something like '[a-z]\.(.*),? ?' would probably …

Member Avatar for kylegetson
0
125
Member Avatar for xabi

I'd use a debugger or start printing out variables at various locations. You'll also want an 'else' case if the login does fail. session_start is usually called before other stuff happens, most specifically before any output is sent to the browser, so your lines #1-3 are probably sending output (empty …

Member Avatar for kylegetson
0
91
Member Avatar for Puster
Member Avatar for Puster
0
101
Member Avatar for sbrohee

why not just remove the outdated one, and symlink it to the correct version? [CODE] rm -rf /usr/bin/perl; ln -s /usr/bin/perl /usr/local/bin/perl; [/CODE] you'll want to back up your old version of perl just in case. (never blindly run any script some just gives you)

Member Avatar for sbrohee
0
127
Member Avatar for fuston05

be careful when using something like fopen with a dynamic variable. If something you didnt expect got into that fopen, it could open files you don't want anyone to open (passwords files, files with database connection details, configuration files, etc.). that being said, you cant refresh anything via php, as …

Member Avatar for kylegetson
0
367
Member Avatar for dfaulted

try casting it as a string. I would guess your $module['id'] is not a string, which likely means that even casting it, won't give you expected results (though it probably won't throw an error). you could try : [CODE] $pos = strpos( (string) $string, $find ); [/CODE]

Member Avatar for kylegetson
0
3K
Member Avatar for lobas

try this: [CODE] # redirect visitors to not have .php in the url RewriteCond %{REQUEST_FILENAME} -f # only if the file requested actually exists RewriteCond %{REQUEST_FILENAME} \.php$ # only if the file ends in .php RewriteRule ^/(.*).php$ /$1/ [R=301,L] # 301 them to the same location, without the .php ending …

Member Avatar for kylegetson
0
159
Member Avatar for tomtetlaw

check to make sure that the directory /var/www/ is readable (at least 444, but more than likely it should be 755) and check the owner and group as well.

Member Avatar for kylegetson
0
322
Member Avatar for kylegetson

I am looking to have both a forward proxy, and a reverse proxy at the same time. It seems as though, when I do this, the Proxy definition I put in place to restrict access to the forward proxy also effects the reverse proxy. [CODE] ... #... inside my virtual …

Member Avatar for kylegetson
0
224
Member Avatar for janessa

I'd suggest an XML sitemap, Digg, and twitter. I've seen digg and Twitter get picked up within hours. I also like delicious, though, I am not convinced it will produce any significant change. Set up some google alerts if you want to see how fast results change. Also I'd set …

Member Avatar for jesy83
-1
801
Member Avatar for gotschai

Try: [CODE] $myVar = "data[1]['items'][4]['items']"; $$myVar = 'xyz'; [/CODE] The two dollar signs I think is what you'll need, though I have never tried it with indexes like this. hope that helps.

Member Avatar for somedude3488
0
102
Member Avatar for ultras1

using php base64_encode and php base64_decode can help as well. never run a query on data you unsure about. also, its a good idea to restrict the permissions of the mysql user your scripts are using, so in case someone does get in, they can't create, alter or drop tables. …

Member Avatar for koldex
0
164
Member Avatar for williebens

I've done some similar work, there is a lot of code already written. Heres one class already written that may help: [url]http://www.micahcarrick.com/04-19-2005/php-zip-code-range-and-distance-calculation.html[/url]

Member Avatar for kylegetson
0
156
Member Avatar for moin123

Yahoo and Bing! (MSN) both have similar services, though the features suck in comparison to Google Webmaster Tools.

Member Avatar for sylstain
0
147
Member Avatar for sarithak

Your issue is your using single quotes ' instead of double quotes " as a string with a variable in it. on line 48 you have: [CODE] createthumb('$dir1','$dir/thumbs/$photo1',100,100);//Not working(problem here only) [/CODE] Try: [CODE] createthumb("$dir1","$dir/thumbs/$photo1",100,100);//Not working(problem here only) [/CODE] the problem is, that when you use single quotes '$myvar' will …

Member Avatar for sarithak
0
150
Member Avatar for jrosh

if you have an auto increment field, just use mysql_insert_id() to get the last auto increment

Member Avatar for kylegetson
0
136
Member Avatar for mrcb

would it not make more sense to have all this data in 1 table? if your table names are literally differentiated by a number, just add a field to your table structure. So instead of having 62 tables, have 1 table with the following fields: date, user, url, short_url, TableNumber …

Member Avatar for kylegetson
0
176
Member Avatar for ultras

if your looking to concatinate (combine) two strings, in php, use the dot (.). [CODE] $a = "string1"; $b = "string2"; $combinedStrings = $a . $b; [/CODE] But it looks to me like your trying to combine the strings in the wrong place, unless you have a column with the …

Member Avatar for nav33n
0
126