User Profile
Collapse
-
Ok strike that, I've fixed that problem, but now I have another. I can't read or write files on the server. I'm assuming that the permissions just aren't letting me, but I think my server doesn't support chmod. Should I just look for a new server, or is there a way around this? -
This all works when I run on localhost. Would it be different on the server?Leave a comment:
-
-
If I'm on a windows server do I have to use ".\" instead of "./"? Just a thought...Leave a comment:
-
./ on server?
I recently developed a website for my school. I was working off localhost for the development. When time came to upload the server we had didn't accept "./" or "../" as soft paths. Am I doing something wrong? Is there anyway to solve this?
Thanks. -
-
Read data from serverside file?
Hey, This is a pretty simple question. Is there any easy way to read data from a server side file. I know that Javascript is client side. I was thinking you write a php script to get the data, then open that url in Javascipt? Is it possible to use javascript to get the code of a url? Sorry this is probably very noobish. Thanks guys! -
-
haha sorry, so in the main file I have:
then in static-items/menu I haveCode:<?php function writestatic($item) { $path = softrootpath() . '/static-items/'.$item; $f = fopen($path, 'r'); $data = fread($f, filesize($path)); echo $data; } ?>
...Code:<div id="menucontainer"> <div id="menunav"> <ul> <li><a
Leave a comment:
-
Parse interpret code from file?
Hey this is an odd question. So I'm designing a website with certain elements repeating. So I put the code for those sections into individual files, then would have php load the html into the page, so if I wanted to change something I would only have to change it in one place. The problem is that some of the parts contain php code, that is echoed into the document as straight text, and not interpreted. Is there a way to have php do multiple passes,... -
-
Ok guys well here's a simplified example of what I'm trying to do.
I start the proxy using "ssh -D 1080 mchang@192.168. 107.30"
this starts a proxy to another part of the machine (I'm using Solaris 10) on part 1080.
Then I have the php code.
...Code:<?php require_once './HTTP/Request.php'; PEAR::setErrorHandling(PEAR_ERROR_PRINT); $webAddress =
Leave a comment:
-
-
Ok guys thanks for the help. after a little more research I've tracked down my problem. The Flickr API (or at least what I'm using) uses PEAR. and you need to specify a proxy when making an HTTP request. Following the example from: http://www.collicott.n et/jess/examples/php/pear/http_request/
I end up with:
...Code:<?php require_once 'HTTP/Request.php'; $params['proxy_host'] = '127.0.0.1'; //proxy is
Leave a comment:
-
-
-
This was for C++, I was just using exec as an example of what I was looking for, and popen was it. So Thanks!Leave a comment:
-
Get program's return data?
Well this is probably a noob question but here it goes.
How does one go about getting the output from a program?
I know you run system() but that just returns an integer.
Is there perhaps a command similar to exec() in PHP?
Or do you have to have the program you're running write to a file.
Well thanks for the help. -
Passing Arguments to php from command line?
Hi, I have a pretty simple question.
Is it possible to pass arguments to php if you're running it from command line instead of in a browser? Like:
# /usr/local/bin/php test.php Hello
Or could you do something like
#/usr/local/bin/php test.php?arg=He llo
(I tried the later and it didn't work but maybe I did something wrong.) -
Connect through proxy?
Ok this question may seem odd, but I'll do my best to explain it.
I'm writing a script for development purposes so this doesn't need to run in a browser, actually this would be a lot easier if it could, but it can't. I'm running it with:
# /usr/local/bin/php script.php
The script in question uses the Flickr API so it needs to connect to the internet. And here in lies the question. The way I'm connecting to the...
No activity results to display
Show More
Leave a comment: