Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Showing results 1 to 28 of 28
Search took 0.01 seconds.
Search: Posts Made By: davil
Forum: PHP Aug 5th, 2008, 6:21 AM
Replies: 0
Views: 235
Posted By davil
Parsing ICS (eg. google calendar) into PHP arrays

I got some nice code from http://www.xvx.ca/icalevents/

but I think it is incomplete.


The output gives me the following (this is my...
Forum: PHP Dec 19th, 2007, 4:40 AM
Replies: 7
Views: 283
Posted By davil
Re: Opposite of global in functions

In fact when I checked your code there's no need now for the $howlong paramater passing to the function... so here's my new code..

Thanks again...


function CheckDateOld($date)

{
$reportdat =...
Forum: Coder's Corner Lounge Dec 19th, 2007, 3:31 AM
Replies: 13
Views: 470
Posted By davil
Re: Anyone played portal yet?

OBLIVION!!!! the only man for the job..

Oh and to get back on topic I have to say Portal was definitely one of the best games I've played in the last few years... shockingly addictive if only it...
Forum: PHP Dec 12th, 2007, 5:19 PM
Replies: 2
Views: 196
Posted By davil
Re: Removing double spaces with str_replace

Thanks. I'll try that when I get back to work on Monday.
Forum: PHP Dec 12th, 2007, 7:05 AM
Replies: 2
Views: 196
Posted By davil
Removing double spaces with str_replace

I want to replace double spaces with single spaces.

I have been able to do this before :

$new_string=str_replace(" "," ",$old_string)


this worked or I thought it did anyway with other strings...
Forum: PHP Dec 12th, 2007, 6:51 AM
Replies: 7
Views: 283
Posted By davil
Re: Opposite of global in functions

Thanks that does exactly what I need!! I just never thought of it that way
Forum: PHP Dec 7th, 2007, 3:07 AM
Replies: 7
Views: 283
Posted By davil
Re: Opposite of global in functions

Although I have just tried what you said and it doesn't seem to work.
here's my code

$daysold="";

if (CheckDateOld($datestamp,60)){$reportdatefont=$redfont;}
echo "days...
Forum: PHP Dec 7th, 2007, 2:58 AM
Replies: 7
Views: 283
Posted By davil
Re: Opposite of global in functions

Thanks for your concise reply. I get it now.
Forum: Other Programming Languages Dec 6th, 2007, 10:04 AM
Replies: 2
Views: 527
Posted By davil
Re: Command line screen capture

Thanks. that works perfectly now.
Forum: PHP Dec 6th, 2007, 6:11 AM
Replies: 7
Views: 283
Posted By davil
Opposite of global in functions

Hi all,,

Another stupid question from me...

I know that in order to use a variable from your main php within a function you need to use
global $variable

but I was wondering how you can set a...
Forum: PHP Dec 6th, 2007, 5:48 AM
Replies: 12
Views: 520
Posted By davil
Re: Select Non distinct in MySQL

Oh I did and that's where I got thrown off and used the wrong function altogether... but I won't forget this one again. Thanks
Forum: Other Programming Languages Dec 5th, 2007, 5:29 AM
Replies: 2
Views: 527
Posted By davil
Command line screen capture

Anyone know of any useful apps to capture screen to compressed JPG (compression can be set)

I have tried this code in Autoit:

; Capture full screen
; Fist parameter - filename, last - jpeg...
Forum: PHP Dec 4th, 2007, 5:38 PM
Replies: 12
Views: 520
Posted By davil
Re: Select Non distinct in MySQL

Thanks. I knew there was a simpler way. I've seen this before but I keep forgetting the most used code I have and just copy and paste. yep stupid I know but that's me.. I'm gonna print out a list of...
Forum: PHP Dec 4th, 2007, 10:06 AM
Replies: 12
Views: 520
Posted By davil
Re: Select Non distinct in MySQL

Well I have this code working great now except for one thing... I can't get a number of how many results coming back from the DB and store it to a variable. see my variable $total_results... what am...
Forum: PHP Dec 4th, 2007, 3:53 AM
Replies: 12
Views: 520
Posted By davil
Re: Select Non distinct in MySQL

Ok so my original code looked right except I wanted everything so this is what worked for me:

SELECT *, COUNT(*) as count FROM aidahardware GROUP BY primarymac HAVING count > 1
Forum: PHP Dec 4th, 2007, 3:49 AM
Replies: 12
Views: 520
Posted By davil
Re: Select Non distinct in MySQL

I tried that and got the following error:
Unknown column 'count' in 'where clause'
Forum: PHP Dec 3rd, 2007, 9:14 AM
Replies: 12
Views: 520
Posted By davil
Re: Select Non distinct in MySQL

I tell a lie, I've just found what I think I'm looking for :

SELECT primarymac, COUNT(*) as count
FROM aidahardware
GROUP BY primarymac
HAVING count > 1
Forum: PHP Dec 3rd, 2007, 9:12 AM
Replies: 12
Views: 520
Posted By davil
Select Non distinct in MySQL

Hi all,

I know this isn't exactly PHP but I was wondering if there's a simple MySQL query you can use to get back non-distinct lines... like for example you can use SELECT DISTINCT to only give you...
Forum: PHP Nov 21st, 2007, 4:42 AM
Replies: 8
Views: 340
Posted By davil
Re: Simple "foreach" problem

Thanks dawei for your code it really helped me through a tight spot... I modified it a bit to suit my needs and here is the final code. I can't believe I never thought of using arrays like that.... I...
Forum: PHP Nov 20th, 2007, 9:33 AM
Replies: 8
Views: 340
Posted By davil
Re: Simple "foreach" problem

one more thing.... I'm using curl from a command line like this to send the info to the server:


curl -0...
Forum: PHP Nov 20th, 2007, 9:26 AM
Replies: 8
Views: 340
Posted By davil
Re: Simple "foreach" problem

My apologies... I really have done a bad job of explaining it....
from the top, I have info coming in via the URL data - 'PATH_INFO' - that's info about the current state of a PC for example.. I...
Forum: PHP Nov 20th, 2007, 8:46 AM
Replies: 8
Views: 340
Posted By davil
Re: Simple "foreach" problem

parse error, unexpected '$' in W:\www\it2\aida\newinfo.php on line 47
but then I could have told you that just by looking at the code above that it wasn't right. I was just trying to get across what...
Forum: PHP Nov 20th, 2007, 8:06 AM
Replies: 6
Views: 379
Posted By davil
Re: Question regarding data input into PHP/Mysql using something other than GET

I've started a new thread for this (sorry I had hoped to remove the above post but I must be out of time) anyhow the new thread is here:

http://www.programmingforums.org/post137196.html
Forum: PHP Nov 20th, 2007, 8:04 AM
Replies: 8
Views: 340
Posted By davil
Simple "foreach" problem

Ok so I'm getting into PHP and I have a decent sized MySQL/PHP database system working fine but I'm having problems with the foreach command...

When I get the info from a MySQL database I usually...
Forum: PHP Nov 20th, 2007, 6:58 AM
Replies: 6
Views: 379
Posted By davil
Re: Question regarding data input into PHP/Mysql using something other than GET

Ok so I'm getting into this and it seems to be working fine but I'm having problems with the foreach command...

When I get the info from a MySQL database I usually use the following command to...
Forum: PHP Nov 12th, 2007, 12:15 PM
Replies: 6
Views: 379
Posted By davil
Re: Question regarding data input into PHP/Mysql using something other than GET

Ok... I think I get you. I'll look into HTML forms more closely as the PHP side of it is no problem to me. and then I can use POST instead of GET... I also wanted that for security reasons. I might...
Forum: PHP Nov 12th, 2007, 10:09 AM
Replies: 6
Views: 379
Posted By davil
Re: Question regarding data input into PHP/Mysql using something other than GET

Thanks for that... looks very good.. except for the fact that it costs money and we are just one building of many around the country (Ireland) and in order for us to buy software there would be a...
Forum: PHP Nov 12th, 2007, 8:48 AM
Replies: 6
Views: 379
Posted By davil
Question regarding data input into PHP/Mysql using something other than GET

Hi all,

This is kinda more of a general question than simply a PHP question... I'm fairly decent at PHP and BASIC (I use Freebasic to make simple .exe console apps)
I'm struggling at learning C or...
Showing results 1 to 28 of 28

 
Forum Jump



DaniWeb IT Discussion Community
All times are GMT -5. The time now is 2:54 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC