![](https://forums.phpfreaks.com/uploads/set_resources_1/84c1e40ea0e759e3f1505eb1788ddf3c_pattern.png)
zq29
-
Posts
2,752 -
Joined
-
Last visited
-
Days Won
1
Posts posted by zq29
-
-
hmmm you must have some inside info
i saw nothing about localization in his profile so i assumed US
No inside info - I'm in the UK, so was outlining what happens over here, assuming that the US would be similar...
-
Generally, in the UK, you need to have an Online Merchants account with your bank - Similar to the merchants account you have with the CC terminal. Then you'll need an account with a payment gateway, such as SecPay, WorldPay, ProTX, etc.
-
Good luck with that, it's probably proprietary... Get soldering!
-
That's awesome.
-
Go into your display settings and check how high your resolution slider will go. If it only goes up to 640x480 - Your graphics hardware can only support VGA, 800x600 and your hardware supports SVGA, 1024x768 - XGA, 1280x1024 - SXGA, and so on...
-
-
Pretty plain...
[attachment deleted by admin]
-
As much as someone is willing to pay for it...
-
With CS4 out, don't you think that buying something for 8 Pro is a bit stupid?
Bare in mind that Flash CS4 is $699 and that eBay auction for Flash 8 is $333
-
I'd imagine qualifications are only useful if you're applying for a developers position at a company.
Working directly for the end-client as a freelancer or sole trader with qualifications would mean nothing I think - They're unlikely to know or care what languages you use, as long as it does what they want.
A solid portfolio is much better than qualifications in my mind.
-
First up, I don't have (or want) an iPhone. But in what situation would you require the use of a stripped down version of the PHP manual on your phone?
From my perspective, you surely must be developing a script at the time, on your computer, in a world of 'always-on' internet connctivity - And for those that don't have constant connectivity, they surely have an offline version of the manual on their computer and possibly built into their IDE.
-
<?php foreach($files as $f) echo "$f[name]: $f[count]<br />"; ?>
-
Enclose your values in double quotes...
<?php $line .= "\"$orderID\"\t\"$quantity\"\t\"$message1\n$message2\"\t\"$productmail\"\t\"$colormail\"\t\"$sizemail\"\t\"$liconmail\"\t\"$riconmail\"\t\"$ticonmail\"\n"; ?>
-
I'd recommend generating your Excel file in a separate script and linking to it...
<?php header("Content-Type: application/vnd.ms-excel"); header("Content-Disposition:filename=file.xls"); $r = mysql_query("SELECT * FROM `foo`") or die(mysql_error()); while($rr = mysql_fetch_assoc($r)) echo "\"$rr[foo_0]\",\"$rr[foo_1]\",\"$rr[foo_2]\"\n"; ?>
-
A number of options here.
- You could stick with your styling method you used above, but improve it by checking the dimensions of the image first with getimagesize()
- Build a scaled version of the image with the GDLib functions, I believe you can reference remote files as your source with imagecreatefromjpeg() - Check the manual for rescaling, a couple of people have posted up scripts in the comments if you can't figure it out.
- You could stick with your styling method you used above, but improve it by checking the dimensions of the image first with getimagesize()
-
Cool list, I currently only use the Web Developer Toolbar and FireBug, I think I'd find that colour picker one useful - I'll try a couple of them out when I get into the office on Monday I think...
-
I couldn't see an issue around line 43 either, but just a tip while I'm here - It's quicker to type
<?php foreach($_POST as $k => $v) $$k = stripslashes($v); ?>
Than it is to type
<?php $firstname = stripslashes($_POST['firstname']); $lastname = stripslashes($_POST['lastname']); $phone1 = stripslashes($_POST['phone1']); $phone2 = stripslashes($_POST['phone2']); $phone3 = stripslashes($_POST['phone3']); $dobmo = stripslashes($_POST['dobmo']); $dobda = stripslashes($_POST['dobda']); $dobyr = stripslashes($_POST['dobyr']); $ss1 = stripslashes($_POST['ss1']); $ss2 = stripslashes($_POST['ss2']); $ss3 = stripslashes($_POST['ss3']); $dl1 = stripslashes($_POST['dl1']); $dl2 = stripslashes($_POST['dl2']); $dl3 = stripslashes($_POST['dl3']); $dlstate = stripslashes($_POST['dlstate']); $dlexp1 = stripslashes($_POST['dlexp1']); $dlexp2 = stripslashes($_POST['dlexp2']); $dlexp3 = stripslashes($_POST['dlexp3']); $curaddress = stripslashes($_POST['curaddress']); $curcity = stripslashes($_POST['curcity']); $curstate = stripslashes($_POST['curstate']); $rentorown1st = stripslashes($_POST['rentorown1st']); $1stlandlord = stripslashes($_POST['1stlandlord']); $1stphone1 = stripslashes($_POST['1stphone1']); $1stphone2 = stripslashes($_POST['1stphone2']); $1stphone3 = stripslashes($_POST['1stphone3']); $1stmo = stripslashes($_POST['1stmo']); $1styr = stripslashes($_POST['1styr']); $1streason = stripslashes($_POST['1streason']); $preaddress = stripslashes($_POST['preaddress']); $precity = stripslashes($_POST['precity']); $prestate = stripslashes($_POST['prestate']); $rentorown2nd = stripslashes($_POST['rentorown2nd']); $2stlandlord = stripslashes($_POST['2ndlandlord']); $2ndphone1 = stripslashes($_POST['2ndphone1']); $2ndphone2 = stripslashes($_POST['2ndphone2']); $2ndphone3 = stripslashes($_POST['2ndphone3']); $2ndmo = stripslashes($_POST['2ndmo']); $2ndyr = stripslashes($_POST['2ndyr']); $2ndreason = stripslashes($_POST['2ndreason']); $employer = stripslashes($_POST['employer']); $position = stripslashes($_POST['position']); $moincome = stripslashes($_POST['moincome']); $empphone1 = stripslashes($_POST['empphone1']); $empphone2 = stripslashes($_POST['empphone2']); $empphone3 = stripslashes($_POST['empphone3']); $timeatempmo = stripslashes($_POST['timeatempmo']); $timeatempyr = stripslashes($_POST['timeatempyr']); $othersource = stripslashes($_POST['othersource']); $empaddress = stripslashes($_POST['empaddress']); $empcity = stripslashes($_POST['empcity']); $empstate = stripslashes($_POST['empstate']); $pets = stripslashes($_POST['pets']); $eviction = stripslashes($_POST['eviction']); $ref1 = stripslashes($_POST['ref1']); $ref1phone1 = stripslashes($_POST['ref1phone1']); $ref1phone2 = stripslashes($_POST['ref1phone2']); $ref1phone3 = stripslashes($_POST['ref1phone3']); $ref2 = stripslashes($_POST['ref2']); $ref2phone1 = stripslashes($_POST['ref2phone1']); $ref2phone2 = stripslashes($_POST['ref2phone2']); $ref2phone3 = stripslashes($_POST['ref2phone3']); $ref3 = stripslashes($_POST['ref3']); $ref3phone1 = stripslashes($_POST['ref3phone1']); $ref3phone2 = stripslashes($_POST['ref3phone2']); $ref3phone3 = stripslashes($_POST['ref3phone3']); $numadults = stripslashes($_POST['numadults']); $numchildren = stripslashes($_POST['numchildren']); $adult1 = stripslashes($_POST['adult1']); $adultrelation1 = stripslashes($_POST['adultrelation1']); $adult2 = stripslashes($_POST['adult2']); $adultrelation2 = stripslashes($_POST['adultrelation2']); $adult3 = stripslashes($_POST['adult3']); $adultrelation3 = stripslashes($_POST['adultrelation3']); $adult4 = stripslashes($_POST['adult4']); $adultrelation4 = stripslashes($_POST['adultrelation4']); $email = stripslashes($_POST['email']); $message = stripslashes($_POST['message']); $certify = stripslashes($_POST['certify']); ?>
-
You could add them to an array while looping then sort the array with sort(), alternatively, you could use glob() to fetch the directory contents - It lists them alphabetically be default, I believe.
-
The mod_rewrite manual pages do come across as looking harder than it is. If you searched for tutorials on URL rewriting it all becomes a lot more straight forward. You will however need to be able to write (mostly basic) regular expressions. For instance, my previous example is as easy as the following...
#Assuming localhost/database is the webroot RewriteRule ^display/([0-9]+)\.html$ display.php?num=$1
There are a number of advantages, here are a few:
- Readability
- Generally quicker to type
- Easier to convey to people when talking over the phone, for example
- Search engines used to like them a lot better when spidering - How relevant that is today, I don't know
- It can add an extra layer of security, for example, in my example above, display.php is expecting nothing but an integer to come through in $_GET['num'], the regular expression ensures that - Though you'll need other rules to prevent passing anything to the original URL
- Readability
-
You should look into mod_rewrite, which is an Apache module. It enables you to achieve exactly what you're after.
It can rewrite http://localhost/database/display/6.html to http://localhost/database/display.php?num=6 "behind the scenes".
-
Strange, I just ran your code, right clicked it and it correctly wants to save it as a jpeg...
-
You will not be able to "interactively" crop an image with PHP alone, you'd need JavaScript to build the interface with, which I'd imagine is where the proportional restraints will be managed, though backed up with PHP to add a layer of anti-tampering.
You'd pass the coordinates generated by your JavaScript to either PHPs GDLib functions, or something like ImageMagick.
-
-
http://en.wikipedia.org/wiki/Namespace
- I don't know much about C, but is that like defining a constant? You can do that with define()
- I think #pragma is C specific and doesn't have a comparable function(?) in PHP
- PHP pretty much just has arrays and objects as far as I'm aware...
- Can hardly be answered in a bullet point. Break the problem down into modules, and figure it out on a per-module basis
-
http://en.wikipedia.org/wiki/Namespace
-
You'll need to write a (number of) regular expression(s) and implement them with something like eregi() or preg_match().
[SOLVED] Server time
in Miscellaneous
Posted
XMLHttpRequest?