Posts
 
Reputation
Joined
Last Seen
Ranked #2K
Strength to Increase Rep
+0
Strength to Decrease Rep
-0
100% Quality Score
Upvotes Received
3
Posts with Upvotes
3
Upvoting Members
2
Downvotes Received
0
Posts with Downvotes
0
Downvoting Members
0
1 Commented Post
0 Endorsements
~5K People Reached

15 Posted Topics

Member Avatar for GhostDragon

$number is probably null or a srting. Maybe check for missing value and something like is_int() or is_numeric() to check if it's a number. if(!$number || !is_int($number)){ $number = 0; }

Member Avatar for bobgodwin
0
575
Member Avatar for bobgodwin

I need to check the extention of user uploaded files when running a gulp-sass task. I have a file exists function that seems to work, but can't get thereturn value into the task. Here's my gulp file: var fileexists = require('file-exists'); var gulp = require('gulp'); var sassVars = require('gulp-sass-vars'); var …

0
288
Member Avatar for bobgodwin

I need to sort items from multiple columns. I use this to get the id from the columns and format the data: $.fn.serial = function() { var array = []; var $elem = $(this); $elem.each(function(i) { var id = this.id; $(move_selector, this).each(function(e) { array.push( 'id[]=' + this.id ); }); }); …

Member Avatar for bobgodwin
0
492
Member Avatar for bobgodwin

I need to find the largest height & width values in a directory. I've tried to use: if ($handle = opendir('path/to/image')) { while (false !== ($file = readdir($handle))) { if (preg_match('/(jpg|gif|png)/', $file )) { $images[] = $file; list($width, $height) = getimagesize('path/to/image/'.$file); $max_w = max(array($width)); $max_h = max(array($height)); } } closedir($handle); …

Member Avatar for veedeoo
0
400
Member Avatar for bobgodwin

I've been looking for the answer to this problem for a while. I'm using nyroModal in gallery to show php pages. but the popup doesn't resize the first time it loads. I use this link: <a href="galtest.php" class="nyroModal cursor" rel="gal"><img src="img/gallery/thumbs/OldMiami.jpg" class="Tips1" title="In the Backyard Of The Old Miami (Detroit, …

Member Avatar for JavaScprit
0
572
Member Avatar for [csharp]

Try This: echo ' <select name="title" id="title"> '; $query = mysql_query("SELECT title FROM test"); while($row = mysql_fetch_array( $result )) { $opt = $row['title']; echo ' <option value="'.$opt.'">' .$opt. '</option> '; } echo '</select> I've been using PDO for a while, so I hope this is right.

Member Avatar for bobgodwin
0
241
Member Avatar for bobgodwin

I'd like to get a list of folders that don't contain certain files. I'm using this to list directories & files: [code=php]$path = "media"; $dir_handle = @opendir($path) or die("Unable to open $path"); function list_dir($dir_handle,$path) { while (false !== ($file = readdir($dir_handle))) { $exclude = array(".","..","_player_thumbs","Thumbs.db"); $dir =$path.'/'.$file; if(is_dir($dir) && !in_array($file, …

Member Avatar for bobgodwin
0
256
Member Avatar for bobgodwin

I'm building a web page that gets information from a mySQL database. It's setup like this: [CODE]<?php if ($act == "") { //// Get the index page $myQuery = "SELECT * FROM $menu WHERE control='index' "; $result = $dbh->prepare($myQuery); $result->execute(); while($row = $result->fetch()){ $page = $row['title']; $myQuery = "SELECT * …

Member Avatar for hielo
0
159
Member Avatar for bobgodwin

I'm using this code to check if a record exists or not: [CODE] $filename = $_FILES["file"]["name"]; /// FROM FORM $ext = substr($filename, strpos($filename,'.'), strlen($filename)-1); $bull = substr($filename, 0, strpos($filename, '.')); $myQuery = "SELECT * FROM $media WHERE label='$bull' "; $result = $dbh->prepare($myQuery); $result->execute(); $cont = $result->rowCount(); if ($cont == 1) …

Member Avatar for bobgodwin
0
163
Member Avatar for dschuett

Try this thread: [URL="http://www.daniweb.com/forums/thread330656.html"]http://www.daniweb.com/forums/thread330656.html[/URL]

Member Avatar for Member #120589
0
130
Member Avatar for bobgodwin

I'm have a script that outputs files and folders w/ folders as a header and the files listed below. I'd like to sort them alphabetically, but can't seem to figure it out. I think I need to get them into an array. Or use scandir. Here's the code: [CODE]function getDirectory( …

Member Avatar for bobgodwin
0
616
Member Avatar for bobgodwin

I have some code that I'd like to add numbers to. I'm using [iCODE]$count=o;[/iCODE] with[iCODE]++$count[/iCODE] to generate numbers. They start at "1". How do I get them to start at "0"?

Member Avatar for EvolutionFallen
0
124
Member Avatar for bobgodwin

Is there a way to get a distinct value from a table and echo it as a id for a div tag and still have the rest of the values echo too? Say I have a table with these values: category item With 3 categories each having 3 items I'd …

Member Avatar for bobgodwin
0
143
Member Avatar for jhbalaji

[QUOTE=evstevemd;1215389]Here is beautifully simplified solution but it is "either or". I mean [B]either [/B]you persevere and resolve your problem [B]or[/B] you are out :) Here it goes: [URL="http://www.w3schools.com/php/default.asp"]learn quickly PHP[/URL] via this link [URL="http://www.tizag.com/mysqlTutorial/"]Learn MySQL[/URL] via this one Come back and use [URL="http://davidwalsh.name/gmail-php-imap"]this information[/URL] to solve your problem If you …

Member Avatar for jhbalaji
0
254
Member Avatar for bobgodwin

I need to get a file name from a jpg without the extension to use as id in a span tag. Here's the code I'm using: [CODE] <?php $result = mysql_query("SELECT * FROM $data_sales_earrings ORDER BY id ASC"); while($row = mysql_fetch_array($result)) echo " <span id=\"need file name from jpg front\"><img …

Member Avatar for bobgodwin
0
234

The End.