FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Using a heredoc in PHP as in Perl
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Using a heredoc in PHP as in Perl [message #171949 is a reply to message #171946] Sat, 22 January 2011 14:57 Go to previous message
Jerry Stuckle is currently offline  Jerry Stuckle
Messages: 2598
Registered: September 2010
Karma:
Senior Member
On 1/22/2011 2:04 AM, P E Schoen wrote:
> "Jerry Stuckle" wrote in message
> news:ihdh01$tj8$1(at)news(dot)eternal-september(dot)org...
>
>> On 1/21/2011 8:21 PM, P E Schoen wrote:
>>
>>> I downloaded it from http://www.apachefriends.org/en/xampp-windows.html
>>> and now I have XAMPP installed. I copied my website files there, in the
>>> htdocs folder, so I was able to use my EventSubmit.htm to enter data.
>>
>>> But it failed to run the EventProcessor.pl script in the cgi-bin folder.
>>> In fact, I tried to open files located there using the IE8 browser
>>> http://localhost and it gave errors of "Object Not Found", and with just
>>> the URL for the cgi-bin I got a Forbidden error. Yet I was able to
>>> access the files from FileZilla. And when I copied another directory I
>>> was able to use its URL and access the contents. I tried setting
>>> permissions in FileZilla and it complains that the chmod command is not
>>> implemented. I'll try the forum and a search, but it's probably
>>> something simple.
>
>> Unfortunately, Paul, while XAMP is great for setting up Apache,
>> MySQL and PHP, it doesn't come configured for any other products,
>> like Perl. You'll need to do that part yourself.
>
> I found the main problem was that you need to use the C:\xampp\cgi-bin
> folder and not the one I created as C:\xampp\htdocs\cgi-bin. Even when I
> renamed it I could not use it. Then I also had to change the "shebang"
> in my Perl scripts to #!"\xampp\perl\bin\perl.exe", while with my
> ActiveState Perl installation I could run with no change #!/usr/bin/perl
> -T. But then I got errors (from the error.log):
>
> Premature end of script headers: EventProcessor.pl
> C:/xampp/cgi-bin/basic.php is not executable; ensure interpreted scripts
> have "#!" first line
>
> It also complained that the DateTime module was not installed and I
> tried to install it but it still was broken. And as you can see above
> even the PHP script would not run, except perhaps with a non-standard
> first line.
>
> These scripts work fine on the live server. I don't know why an Apache
> server on my machine would need so many adjustments to the scripts. I
> have my cgi-bin folder at the root level, which should correspond to
> C:\xampp\htdocs where I have my other folders for various websites. So I
> use the relative location from my Perl script:
>
> my $dbfile = "../SCGBG/SCGBG_Data.db";
>
> But of course that won't work if the file is one level above the root.
> So it seems that XAMPP may be better for Perl than PHP, but not really
> all that good for either one at this point. I have a discussion going on
> the forum:
>
> http://www.apachefriends.org/f/viewtopic.php?f=16&t=44187
>
> I have since resolved some of the problems.
>
> Thanks,
>
> Paul

It is the same Apache, PHP and MySQL that your hosting company is using
(except maybe the versions). The ONLY difference is that the three are
packaged all together and preconfigured to run. It makes for a much
simpler installation because you don't have to manually configure for a
majority of installations. It works for the vast majority of basic PHP
installations.

If you install the individual packages and configure them the same way
as in XAMP, you will get *EXACTLY* the same results. It just takes more
work.

If you need further help in configuring Apache, I suggest you ask in
alt.apache.configuration.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex(at)attglobal(dot)net
==================
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Placing an URL in email
Next Topic: HOW TO MAKE MONEY ONLINE? MOST RICH PEOPLE ACHIEVE FROM FOREX
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Fri Sep 20 17:30:27 GMT 2024

Total time taken to generate the page: 0.04504 seconds