When PHP is run from the command line the apache settings are not used. You are used to put any php setting in your httpd.conf or in a virtual host. Running from CMD you dont have that confgifile anymore.
Make a configfile in which you put your settings and run PHP with the -c option.
mcvdmvs...
I'm struggeling with configuring Apache 1.3. I want to set an environment variable and set logfiles to a dynamic name. I rewrite a part of the url, get the prefix (which is the name of the website i want to load) and set the document root with a rewrite rule.
<VirtualHost *>
# Rewrite...
But beware. Foreach works with copies. So in the above example $value is a copy of the value in the original array. Modifying this value will not alter the original value in the array.
mcvdmvs
"It never hurts to help" -- Eek the Cat
You are using class and object functions at the same time.
Classfunctions don't have objects, so $this simply doesn't exists.
Try making an object first and then call the functions
function onemore()
{
$this->playarray();
}
}
myarray = new myarray()
myarray->onemore();
Or...
First of all, this is no OOP. OOP is about classes and objects. This is just normal PHP.
Second, i would like to try to help you but i'm not going to copy-paste your code an try figuring out what's wrong. Please supply an error-code or formulate your question better.
mcvdmvs
"It never...
A file, like WMV, has metadata. This metadata is in the head of the file. WMV is encrypted and i don't know of a way to uncrypt it and read the head.
mcvdmvs
"It never hurts to help" -- Eek the Cat
I would like to get the title and description from a wmv file. I can't find any documentation about how it can be done in PHP, or any example scripts.
Does somebody has experience with this, and point me in de right direction or to some documentation?
mcvdmvs
"It never hurts to help"...
Remember: only a page opened with Javascript can be closed (eg with the window.open function), it's not possible to close a window that was opened by a user.
mcvdmvs
"It never hurts to help" -- Eek the Cat
Hi Dan,
You should try reading the manual and a tutorial. Have a look at the beginners guide at: http://wiki.python.org/moin/BeginnersGuide
And the answer to your question is yes.
Regards Mick
mcvdmvs
"It never hurts to help" -- Eek the Cat
When you want to use stdout instead of print use the following:
from sys import stdout
def main():
stdout.write("Hello World")
main()
Hope this helps
mcvdmvs
"It never hurts to help" -- Eek the Cat
I'm always very busy escaping quotes, so i prefer printf or sprintf:
printf ("<a href='%s' class='css_class'>%s</a>\n", 'www.link.com', 'Richy\'s site');
Expecially when you are populating tables in html from db results, this makes your code very readable.
mcvdmvs
"It never hurts to...
In many projects gettext is used. Based on a php-file with gettext or _ in it, gettext generates a list of words that needs to be translated.
When translated, put the files in de correct folders and set the language via setlocale(LC_MESSAGES, 'en_GB') to the correct language. When no...
You are using the mysql function password, this function makes a hash and is therefor not reversible.A very save way of storing passwords.
When you want users to recover lost passwords, offer them a way to generate a new one instead, using there e-mailaddress. Or don't put the password hashed...
Javascript from PHP:
/**
* array_unique -- Removes duplicate values from an array
*
* array_unique() takes input array and returns a new array without duplicate values.
* Note that keys are NOT preserved. array_unique() sorts the values treated as string at first, then will keep the first key...
I used margins at 50%, auto etc.
However it seems that 10% is the correct margin. That wonders me so much, that i am afraid to use it.
I did some nesting as well, but after three nested divs i conclude that it isn't possible as well. So maybe only the following js sollutions helps:
// align...
Hi all,
I would like to vertically align a div on the page, so it's exactly centered. But I can't get it to work. I don't want to use a table.
vertical-align isn't working either, i guess because the browser don't knows the heigth of the page.
mcvdmvs
"It never hurts to help" -- Eek...
Hi,
I have a table consisting of two columns and one row. In both cells there is a from field. When a user fills in te last field in the last cell i would like to have a pop-up that asks if there must be a new row inserted into the active table. (ofcourse with the two fields again).
I cant...
Use a multidimensionalarray. Get all marks ie: ferrari, porsche and jaguar as the first element, and fill the next element with the types.
$car['ferrari']['testarossa']
$car['ferrari']['maranello'] etc.
Or, and that is i think not what you want. Use javascript to reload the page with the...
Can you please be more specific? A form is submitted via POST or GET and the data is available as an array on the new page.
Or do you want to be more dynamic? With javascript or so?
Everytime A is changed you want to query the database? mcvdmvs
"It never hurts to help" -- Eek the Cat
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.