Web Development Questions That Don't Need Their Own Thread v2
3,079 replies, posted
[QUOTE=exiam;33664625]you're making me look bad ಠ_ಠ[/QUOTE]
bitch please, you're making yourself look bad.
[QUOTE=Jelly;33666744]bitch please, you're making yourself look bad.[/QUOTE]
Kids, please.
[QUOTE=nikomo;33639464]Yeah, I used intval.
$id = intval($_GET['id']);
That should do the trick.[/QUOTE]
You can type cast in PHP like this:
[code]
$id = (int) $_GET['id'];
[/code]
[QUOTE=jaybuz;33674756]You can type cast in PHP like this:
[code]
$id = (int) $_GET['id'];
[/code][/QUOTE]
It's also pretty faster, although intval accepts a base parameter (which you don't need in this situation).
Check this out: [url]www.toyota.com/itsacar/[/url]
"HTML5, WebGL, and multiplayer experience" (looks like socket.io) and I don't see any Flash, either!
all the videos are flash
donations or ads..donations or ads..
hm
p.s. fuck you stinkyjoe, "brb need to restart" YOU NEVER CAME BACK
[QUOTE=exiam;33680026]donations or ads..donations or ads..
hm
p.s. fuck you stinkyjoe, "brb need to restart" YOU NEVER CAME BACK[/QUOTE]he doesn't like you
[QUOTE=cas97;33679701]Check this out: [url]www.toyota.com/itsacar/[/url]
"HTML5, WebGL, and multiplayer experience" (looks like socket.io) and I don't see any Flash, either![/QUOTE]
I was wondering what parts aren't compatible with Firefox. :(
[editline]12th December 2011[/editline]
[QUOTE=TehWhale;33679988]all the videos are flash[/QUOTE]
They seem to using <video> with webm files.
[QUOTE=jaybuz;33680074]I was wondering what parts aren't compatible with Firefox. :(
...[/QUOTE]
The advertising budget.
I'm just glad the snow is Chrome only.
While I'm not complaining, I wonder why that is.
Anyone with any experience on making a log-in form using Javascript? I'm going back and forth in circles; luckily having fun and learning here and there.
Why doesn't this work for fuck's sake
[img]http://img835.imageshack.us/img835/4783/20111212195214.png[/img]
I own a website through godaddy.com
I also have a tumblr account.
I know that tumblr lets you make a real domain name for your blog, but they host your domain (store, ownership of it)
Is there a way to make my godaddy owned domain forward to that tumblr account without the use of redirecting (changing the address bar) and without the use of iframes?
[QUOTE=Sprite;33692436]I own a website through godaddy.com
I also have a tumblr account.
I know that tumblr lets you make a real domain name for your blog, but they host your domain (store, ownership of it)
Is there a way to make my godaddy owned domain forward to that tumblr account without the use of redirecting (changing the address bar) and without the use of iframes?[/QUOTE]
[url]http://en.wikipedia.org/wiki/Reverse_proxy[/url]
[QUOTE=TerabyteS_;33688665]Why doesn't this work for fuck's sake
[img]http://img835.imageshack.us/img835/4783/20111212195214.png[/img][/QUOTE]
Because you're trying to use the wrong function? Otherwise, no idea.
[img]http://puu.sh/aw5I[/img]
I run a small community and we recently rebuilt our forums on SMF while the old ones were on MyBB.
What could cause scrolling to be jerky on the new one? It definitely isn't smooth.
[QUOTE=Agent766;33693534]I run a small community and we recently rebuilt our forums on SMF while the old ones were on MyBB.
[/QUOTE]
Why?
MyBB is fucktons better than SMF imho.
It wasn't up to me. I'm happy with how it's turning out though.
We still have an issue with jerky scrolling compared to other sites.
[QUOTE=Sprite;33692436]I own a website through godaddy.com
I also have a tumblr account.
I know that tumblr lets you make a real domain name for your blog, but they host your domain (store, ownership of it)
Is there a way to make my godaddy owned domain forward to that tumblr account without the use of redirecting (changing the address bar) and without the use of iframes?[/QUOTE]
[url]http://www.tumblr.com/docs/en/custom_domains[/url]
Is that what you were talking about? You can point any domain you own at your tumblr blog.
So, I'm developing a miniature application and using PDO for the first time. I've made a method which handles Executions and Preparations. But i'm not sure how to do the UPDATE or DELETE from statements as they don't seem to be doing anything, what so ever.
Any clues?
The code is like so:
[code]
public function afPDO_EXEC($query,$data) {
$sth = $this->DBH->prepare($query);
$sth->execute($data);
}
[/code]
If I were to call afPDO_EXEC("delete from user where id = ?",1);
or
afPDO_EXEC("delete from user where id = ?",array(1));
nothing happens at all, but if I were to use an insert. Everything works dandy, any clues?
[QUOTE=graymic;33705462]So, I'm developing a miniature application and using PDO for the first time. I've made a method which handles Executions and Preparations. But i'm not sure how to do the UPDATE or DELETE from statements as they don't seem to be doing anything, what so ever.
Any clues?
The code is like so:
[code]
public function afPDO_EXEC($query,$data) {
$sth = $this->DBH->prepare($query);
$sth->execute($data);
}
[/code]
If I were to call afPDO_EXEC("delete from user where id = ?",1);
or
afPDO_EXEC("delete from user where id = ?",array(1));
nothing happens at all, but if I were to use an insert. Everything works dandy, any clues?[/QUOTE]
[php]
$this->DBH->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
[/php]
Put that before your PDOStatement::execute call, and see if anything pops up.
[QUOTE=StinkyJoe;33706682][php]
$this->DBH->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
[/php]
Put that before your PDOStatement::execute call, and see if anything pops up.[/QUOTE]
Thanks bud, really did help. I'm relatively new to coding up stuff with PDO from scratch. But I must say I do prefer it a lot!
[php]
if(TIME_NOW >= $row['time']+172800) {
$sum = 2;
$dbtime = $row['time']-172800;
while(TIME_NOW >= $dbtime) {
++$sum;
$dbtime = $dbtime-86400;
}
$content .= $lang->sprintf($lang->time, $sum);
}
[/php]
Why doesn't that work? The condition returns false even when it shouldn't.
How do you make it so when you scroll down a page different images or divs move. I'm presuming jquery but can't really find anything on the topic.
Eg. when you scroll a certain distance down an image comes out from the side of the screen
wasn't there something called waypoint that did something that
[QUOTE=Adzter;33722625]How do you make it so when you scroll down a page different images or divs move. I'm presuming jquery but can't really find anything on the topic.
Eg. when you scroll a certain distance down an image comes out from the side of the screen[/QUOTE]
You can do that with css.
[QUOTE=Adzter;33722625]How do you make it so when you scroll down a page different images or divs move. I'm presuming jquery but can't really find anything on the topic.
Eg. when you scroll a certain distance down an image comes out from the side of the screen[/QUOTE]
You check the offset from the div/image to the top of viewport - then when the page is scrolled you check the scroll height compared to the original div/image offset, when it becomes zero, you add: [code]position: fixed; top: 0;[/code]
Sorry, you need to Log In to post a reply to this thread.