Search Results

Showing results 1 to 40 of 59
Search took 0.01 seconds.
Search: Posts Made By: digital-ether ; Forum: PHP and child forums
Forum: PHP 13 Days Ago
Replies: 9
Views: 461
Posted By digital-ether
Having PHP handle static files, such as JS and CSS and gzipping them on the fly is inefficient.

A better approach is to have PHP write a gzipped version of the static file to the filesystem.
...
Forum: PHP 30 Days Ago
Replies: 7
Views: 446
Posted By digital-ether
This it the embed code for that particular page:

<object width="425" height="344"><param name="movie" value="http://www.youtube.com/v/NMAYr709-9Y&hl=en_US&fs=1&"></param><param...
Forum: PHP 30 Days Ago
Replies: 7
Views: 409
Posted By digital-ether
To explain how this is done:

First you make a http request to the page you want to parse.

eg:

$url = 'http://example.com/';
$content = file_get_contents($url);

Then you parse the HTML....
Forum: PHP 30 Days Ago
Replies: 10
Views: 790
Posted By digital-ether
You can send SMS for free to most carriers by sending an email to their Email to SMS gateway.

A list of carriers is here:
http://en.wikipedia.org/wiki/List_of_carriers_providing_SMS_transit
...
Forum: PHP 33 Days Ago
Replies: 109
Views: 3,793
Posted By digital-ether
adler32 and crc32 were developed for a different purpose then security. They are used more for verifying data integrity or error detection.

They do not provide means to secure against intentional...
Forum: PHP 34 Days Ago
Replies: 109
Views: 3,793
Posted By digital-ether
CRC32 should NOT be used at all. Not as the last hash output, or before you hash it again with a secure hash. Just not at all.

Even if you take a crc32 hash and rehash it with sha256. It doesn't...
Forum: PHP Nov 13th, 2009
Replies: 109
Views: 3,793
Posted By digital-ether
@OmniX The length of the salt does matter. The salt should be random, yes, but it should also be long enough to make the precomputation attack infeasible.

I've also read those statements that the...
Forum: PHP Nov 12th, 2009
Replies: 109
Views: 3,793
Posted By digital-ether
Wouldn't you just love to prove it?
http://en.wikipedia.org/wiki/Millennium_Prize_Problems
I think I'll try and solve it tonight. Or maybe just buy a lottery ticket, better chance of winning that.
Forum: PHP Nov 12th, 2009
Replies: 109
Views: 3,793
Posted By digital-ether
function HASHITBAY_BE($toHash)
{
$maxLength = 42; //maximum length of the salt
$hashMethod = 'whirlpool' //encryption method...
$saltLength = strlen($toHash)*3;
if($saltLength >...
Forum: PHP Nov 11th, 2009
Replies: 2
Views: 576
Posted By digital-ether
The examples at http://www.sitepoint.com/print/1105/ should do...
Forum: PHP Nov 11th, 2009
Replies: 4
Solved: header problem
Views: 249
Posted By digital-ether
Are you using ob_start() before any PHP code?

eg:

<?php
ob_start();
include_once('session.php');
include_once('config.php');
// .. etc...
?>
Forum: PHP Nov 6th, 2009
Replies: 18
Views: 5,155
Posted By digital-ether
Looks great. I modified the class I wrote a bit after looking at your code.

Just a few suggestions:

You could optimize the string concatenation.

$buffer .= hash($algo, $input . $salt);
...
Forum: PHP Nov 6th, 2009
Replies: 18
Views: 5,155
Posted By digital-ether
Thought I'd write an example:

note: for PHP4 just remove the "public static" in front of each function declaration.

The class:

/**
* Generate cryptographic Hashes for passwords
*
*...
Forum: PHP Nov 5th, 2009
Replies: 18
Views: 5,155
Posted By digital-ether
There really is no reason to use 2 way encryption on passwords. Retrieving the password is not the concern, gaining access to their account is. So if the user forgets their password, send them a...
Forum: PHP Nov 2nd, 2009
Replies: 109
Views: 3,793
Posted By digital-ether
Sorry for resurrecting an old thread. But it was referenced recently and I thought I'd add to it.

crc32b should not be used with passwords as it is an insecure hash function. ...
Forum: PHP Oct 14th, 2009
Replies: 107
Views: 3,529
Posted By digital-ether
Here is the tutorial on how to get seeking possible in the JW Player.
http://www.longtailvideo.com/support/tutorials/HTTP-Video-Streaming

This allows seeking to a not yet buffered part of the...
Forum: PHP Oct 11th, 2009
Replies: 107
Views: 3,529
Posted By digital-ether
I just tried the video capture and the other tools they have, that is some really good stuff. Thanks for recommending it.

Btw, the link is:
http://www.nchsoftware.com/
Forum: PHP Oct 11th, 2009
Replies: 107
Views: 3,529
Posted By digital-ether
For transcoding media files you're best bet is FFMpeg, http://en.wikipedia.org/wiki/FFmpeg

You can invoke it from the command line. If you want a graphical interface, VLC is also Open Source and...
Forum: PHP Oct 9th, 2009
Replies: 107
Views: 3,529
Posted By digital-ether
A tutorial on how to create your first PHP page. A single step by step, that would be the easiest way to start a total noob on PHP.
Forum: PHP Oct 5th, 2009
Replies: 8
Views: 284
Posted By digital-ether
You can't place a WHERE clause inside a SELECT statement.

http://dev.mysql.com/doc/refman/5.1/en/insert.html

However, you can do the SELECT and then INSERT if needed.

SELECT 1 FROM...
Forum: PHP Oct 5th, 2009
Replies: 6
Views: 536
Posted By digital-ether
I find the stream_context_create() function simpler then cURL since you don't have to remember or look up all those CURLOPT_* constants.


// the xml to send
$xml = 'your xml payload';

//...
Forum: PHP Oct 4th, 2009
Replies: 6
Views: 536
Posted By digital-ether
PHP5+, you can also use the stream functions.
http://www.php.net/manual/en/book.stream.php
http://www.php.net/manual/en/function.stream-socket-client.php

or the similar fsockopen() in PHP4:...
Forum: PHP Sep 28th, 2009
Replies: 26
Views: 1,827
Posted By digital-ether
It is actually very basic.

The only odd operations used are:

% - modulo or remainder
chr() - return the character represented by a number in ASCII table
floor() - round down the float to an...
Forum: PHP Sep 18th, 2009
Replies: 9
Views: 1,011
Posted By digital-ether
Which bz library? Do you mean zlib? Is this in mysql or PHP?

You can just decompress the result in the SQL query:

SELECT uncompress(test) as test FROM `table` WHERE `compressed` =...
Forum: PHP Sep 8th, 2009
Replies: 4
Views: 381
Posted By digital-ether
Something not mentioned on that link is that POST requests are not cached. GET requests are, and thus reduce the load on your server. Subsequent requests using GET will appear much faster, since the...
Forum: PHP Jul 1st, 2009
Replies: 4
Views: 494
Posted By digital-ether
Here is an interesting page that could be used to create a password strength meter:

http://www.lockdown.co.uk/?pg=combi
Forum: PHP Jun 16th, 2009
Replies: 5
Views: 551
Posted By digital-ether
Yes, is is possible with wordpress. You can create custom pages with the funcitonality you want, through an extension.



Josh, I wouldn't write wordpress off because it got hacked in shared...
Forum: PHP Jun 2nd, 2009
Replies: 24
Views: 1,391
Posted By digital-ether
On windows you just have to download one of the windows binaries. Here is the link again to an unofficial windows builds:

http://ffmpeg.arrozcru.org/builds/

For example, the latest build they...
Forum: PHP May 31st, 2009
Replies: 24
Views: 1,391
Posted By digital-ether
Here is a bit on uploading files in PHP:
http://www.php.net/manual/en/features.file-upload.post-method.php

You can convert the file to flv after uploading using FFMPEG and FLVTool2 for the...
Forum: PHP Mar 31st, 2009
Replies: 8
Views: 767
Posted By digital-ether
;ls -la is a linux shell command. The first part, ; is a command delimiter.

So if that were passed to the linux shell, it would first delimit any previous command, and then call the command ls...
Forum: PHP Mar 26th, 2009
Replies: 4
Views: 440
Posted By digital-ether
ctype_space seems to check if the string is composed of all spaces.

I think the function to use would be ctype_graph.
http://in.php.net/manual/en/function.ctype-graph.php

This makes sure all...
Forum: PHP Mar 17th, 2009
Replies: 12
Solved: About sleep()
Views: 936
Posted By digital-ether
What you want is called IPC (Inter Process Communication).
http://en.wikipedia.org/wiki/Inter-process_communication

This is why it is better to write a deamon (start a child process) using PHP...
Forum: PHP Mar 15th, 2009
Replies: 12
Solved: About sleep()
Views: 936
Posted By digital-ether
Are you trying to just input this yourself from the command line or want PHP to do it?

see: http://www.unixgeeks.org/security/newbie/unix/cron-1.html

Basically you need to use: crontab -e
...
Forum: PHP Mar 15th, 2009
Replies: 18
Views: 100,703
Posted By digital-ether
Just to clear things up:



str_replace() will remove *all* occurrence of whitespace.

$str = str_replace(' ', '', $str);

So it solves the problem in the original post.
Forum: PHP Jan 10th, 2009
Replies: 2
Views: 830
Posted By digital-ether
Regular expressions are quite simple.

Instead of matching exact characters like in your str_replace() you match patterns.

The pattern is held in two delimiters, denoting the start and end of...
Forum: PHP Nov 30th, 2008
Replies: 5
Views: 1,650
Posted By digital-ether
Abstract classes can also be used to hide complex code, while still being extensible.

Say implementing the Animal class was quite involved and complex, now someone who didn't know about Animals...
Forum: PHP Aug 31st, 2008
Replies: 11
Views: 1,020
Posted By digital-ether
See also the <button> tag. It has better support for this as it allows a label different from the value attribute.

http://www.w3.org/TR/html401/interact/forms.html#h-17.5


eg:

<button...
Forum: PHP Aug 31st, 2008
Replies: 5
Views: 914
Posted By digital-ether
If I follow correctly, the result of the query should give something like:

ProjectTitle, Fname, Lname
-------------------------------
project1, joe, blow
project1, sam, bam
project2, jim, beam...
Forum: PHP Aug 24th, 2008
Replies: 20
Views: 11,197
Posted By digital-ether
I wrote a class that you can use for the validation with SMTP. It will only work on Linux as Windows doesn't have the getmxrr() function or other DNS functions.
If needed on windows, one can...
Forum: PHP Aug 24th, 2008
Replies: 20
Views: 11,197
Posted By digital-ether
By the way, some email domains will actually have other domains relaying emails in their behalf.

In order to validate the domain portion of the email, and find the correct host to connect to (the...
Showing results 1 to 40 of 59

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC