Re: Re: PHP error on my site after transfer to another hosting

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2013/12/22 Maciek Sokolewicz <maciek.sokolewicz@xxxxxxxxx>:
> On 22-12-2013 21:55, Ryan Wagner wrote:
>>
>> Did you tried turning off the E_NOTICE warning.
>>
>> error_reporing(E_ALL || ~E_NOTICE);
>>
>> On Sun, 22 Dec 2013 22:49:42 +0200, EyeLand <ournet.biz@xxxxxxxxx> wrote:
>>
>>> look there the code of these files:
>>>
>>> 2) there is index.php file:
>>> https://gist.github.com/eyeland/8b471bf7ca9f6f3f76a7#file-index-php
>>> 3) there is _design.php file:
>>> https://gist.github.com/eyeland/26f3b57fb3b8d271beef#file-_design-php
>>>
>>> 2013/12/22 Jim Giner <jim.giner@xxxxxxxxxxxxxxxxxx>:
>>>>
>>>> On 12/22/2013 3:32 PM, EyeLand wrote:
>>
>> <snip>
>>>>
>>>> First - go to one of the files with an error, find the line # cited
>>>> and show
>>>> us the code that is there if you haven't figured it out by then.
>>>>
>
> Ok,
>
> first of all;
> Ryan: do NOT top-post. The mailinglist rules kindly ask you to
> *bottom-post*. So please do that in the future.
>
> Second:
> Telling someone to ignore errors is one of the most stupid suggestions you
> can make. Imagine going to a garage because your car makes a strange sound.
> If the mechanic tells you "have you tried ignoring it?". Would you be happy
> with that answer? hell no! I'd switch garages immediately.
>
> Now, to the OP (=Original Poster); obviously, you have very very little
> knowledge of PHP and are afraid to look at the code yourself. The error
> messages are very clear on what is hapenning. In short:
> 1. "PHP Warning: extract() expects parameter 2 to be long, string given in
> /var/www/h1678/data/www/lounge.md/data/content/index.php on line 19"
>
> This means that on line 19 of index.php:
> extract($pageApartments,'EXTR_OVERWRITE');
> The second argument, which is 'EXTR_OVERWRITE' is a string, and not long
> (which is a type of number). This is because you used... a string (duh)...
> while the manual tells you to use a *constant* with the name EXTR_OVERWRITE
> (a constant is never enclosed in quotes!)
>
> Remove the quotes and... whoa! it got rid of the error!! It's a miracle!
>
> Next warning:
> 2. Undefined variable: apartments_title in
> /var/www/h1678/data/www/lounge.md/data/content/index.php on line 23
>
> What might this mean? Well... I would hazard that apartments_title is
> simply... not defined... anywhere prior to being used. Your best bet would
> be to define it prior to using it. Comming back to the garage example;
> imaging coming back to the garage and asking "I came for my car", wouldn't
> their first response also be "which car do you mean?". Well, PHP also has no
> idea what that variable is, since it has never seen it before. If it knew,
> it wouldn't spew out the error.
>
> All other warnings/notices/etc. are variations of these two.
>
> The reason you might not have seen them before is most likely because your
> previous host hid the errors. This is possible, though very unwise. So well
> done on switching to a better host. Now try following the directions given
> in the warnings and notices.
>
> - Tul
>

1) I delete the quotes on line 19 on index.php and on site now I see
all photo, that is good, but I not see the text on site
2) on line 23 on index.php how can I define $title="$apartments_title"; ?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php





[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux