Advertisement:

Author Topic: Installation problems  (Read 7816 times)

ljhelbo

  • Newbie
  • *
  • Posts: 20
Installation problems
« on: October 16, 2010, 12:34:09 pm »
Now I have tried to install version 1.0. It works better for me, but i still have some problems.

During the installation I have a problem in step 4. If I select one or more categories and click next, I get a blank screen and nothing more happens. If instead I select Skip, the installation completes. The admin-password is not shown, but it is send to me via email, so no real problem in that.

Next I delete the oc-installer folder. Click to log in to the admin panel. I type in the username and password that I got via email. This is accepted, but again I get a completely blank screen. (Even the source code of that page is empty).

I have tried to guess, what might be wrong. During the installation step 4, I presume that the program must create a folder for each category - where the items must later be stored. Could the problem be that I am running Windows (Wamp) on the server (with different slashes expected)? .... yes, I know that I should change my server to a decent operatingsystem, and yes I will do that, but I need a little more time to complete it ;-)

When I try log into the admin panel, I go to the page /osclass/oc-admin/index.php, which redirects me to /osclass/oc-admin/main.php. I tried to look into the sources of these files and noticed that you use dirname(__FILE__), to define the different paths. I tried to open the file oc-load.php and add the line echo(APP_PATH.'/config.php'); after line 29. This gives an output of K:\wamp\www\sallnet_dk\oc/config.php - where oc is my installation-folder. Here I wonder if the different slashes might confuse something? When I write something in PHP, I use $_SERVER["DOCUMENT_ROOT"] + the installation folder. This gives me normal slashes, but I don't know, if this has any significance.

_CONEJO

  • Administrator
  • Hero Member
  • *****
  • Posts: 4689
Re: Installation problems
« Reply #1 on: October 16, 2010, 04:46:18 pm »
Hi ljhelbo,

We detected some problems in various configurations. We currently don't have a windows machine to test OSClass, but we'll getting one soon. Did you try installing it again? Categories don't create any folder, they're stored in the database.

We'll investigate the issue and comunicate to you as soon as we have something!

ljhelbo

  • Newbie
  • *
  • Posts: 20
Re: Installation problems
« Reply #2 on: October 16, 2010, 08:20:03 pm »
Thank you very much, I really want to make this work  ;)

Anyway I really think it is an issue of different terminologies of folders and path. In the admin-part I get no output whatsoever. So what I suspect there is that the program can not find the themes-folder?

I can however now install the program. The public interface works, I am able to register as user and place an add. But also here there seems to be a folder issue. When I have placed an add, I get an email to validate the add. But when i click the validation-link I am redirected to a non-existing folder.

I made an add saying I wanted to sell a rabbit, and when validating the add, I was redirected to the folder: http://www.sallnet.dk/oc/for-sale/animals/rabbit-1 The same thing happens, when I go to the user interface and make a search for my add. It turns up fine in the list (so the data is there in the database), but when i click on the title of the add, I am send to the above link. This was why I thought there should be folders for the categories.

_CONEJO

  • Administrator
  • Hero Member
  • *****
  • Posts: 4689
Re: Installation problems
« Reply #3 on: October 16, 2010, 09:23:54 pm »
Oh!

For that nice URL is needed the "mod_rewrite" extension on your server (Apache). You could disable that from the admin panel, under Settings >> "Permalinks" . Uncheck that option or install the mod_rewrite module of Apache.

You could do that in several ways, usually (at least under Linux) you only have to go to a console/shell and write "a2enmod rewrite" (without quotes). This could also be usefull : http://roshanbh.com.np/2008/04/check-enable-mod_rewrite-apache.html (I didn't try it since I develop under Linux) but it should work for you.

Please, tell me if that worked.

We're still looking for a solution of the blank page at the installation.

ljhelbo

  • Newbie
  • *
  • Posts: 20
Re: Installation problems
« Reply #4 on: October 16, 2010, 09:41:08 pm »
But mod_rewrite is loaded. You can see the configuration here:

http://home.salldata.dk/temp/test.php

(made the way your link said)

ljhelbo

  • Newbie
  • *
  • Posts: 20
Re: Installation problems
« Reply #5 on: October 16, 2010, 10:59:39 pm »
I think I'm getting closer now  ;)

In the file /oc-admin/themes/modern/header.php

you have at a number of places written '<?' instead of '<?php'

when I start to change that, things start showing up on the previously blank screen. I did a quick search for it and it seems to be a possible configuration in php. Some people mention that they prefer to configure their server to only accept <?php, to avoid problems with xml.

ljhelbo

  • Newbie
  • *
  • Posts: 20
Re: Installation problems
« Reply #6 on: October 16, 2010, 11:34:43 pm »
I now inserted php in this file and that helped a lot. I believe the admin-panel is now working. But probably the same issue is there in other files as well.

I think I am still missing a stylesheet for the header in the admin panel. There is only text.

And secondly I believe I am also missing something in the public page. Now I could see the preview in the admin panel, I realise that something is wrong. I only have the header and a blank page below it. That must be wrong.

You can see how it looks here: http://www.sallnet.dk/oc/

Something is missing, right?

ljhelbo

  • Newbie
  • *
  • Posts: 20
Re: Installation problems
« Reply #7 on: October 16, 2010, 11:48:58 pm »
Following this I tried to do a global search replace for this  :o

first I replaced <? with <?php and then <?phpphp with <?php

That made the categories appear on the frontpage. At first - when i clicked on one of those categories, I got a "page not found". But now I simply deactivated permalinks.

_CONEJO

  • Administrator
  • Hero Member
  • *****
  • Posts: 4689
Re: Installation problems
« Reply #8 on: October 16, 2010, 11:57:22 pm »
Here we are!

All <? can not be replace by <?php. That's... wrong. You pointed it out correctly, it was a problem with short_open_tag configuration ( http://php.net/manual/en/function.echo.php )

We used in some places "<?=" which is an alternative code to "<?php echo" so, changing <?= to <?php may cause some problems. We're aware of that problem (not everyone use short_open_tag) and we're working to correct it as soon as posible.

Thanks for your help, we also know that the .htaccess doesn't work on all configuration, so we'll work on that too. Maybe the union of those two problem make your installer not to work propertly.

As always, we'll inform you as soon as we got something!

Thanks a lot, your help and feedback make us to improve OSClass!

_CONEJO

  • Administrator
  • Hero Member
  • *****
  • Posts: 4689
Re: Installation problems
« Reply #9 on: October 17, 2010, 12:04:47 am »
Could you try to modify your .htaccess file (it's on the root os OSClass)  and put this

Code: [Select]
RewriteBase /oc/
under

Code: [Select]
RewriteEngine On
It should look like
Code: [Select]
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /oc/

#Pages: contact, feed, sitemap
RewriteRule ^contact(.html)?$ index.php?action=contact [NC,L]
RewriteRule ^feed.xml$ index.php?action=feed [NC,L]
RewriteRule ^sitemap.xml$ index.php?action=sitemap [NC,L]

#Advertisements
RewriteRule -(\d+)$ item.php?id=$1 [NC,L]

#Static pages
RewriteRule -p(\d+)$ page.php?id=$1 [NC,L]

#Redirect 301 of first page of category
RewriteCond %{REQUEST_URI} !((oc-admin)|(oc-content)|(oc-includes)|(oc-installer)).*
RewriteRule ^([a-zA-Z\_\-]+/([a-zA-Z\_\-]*/)?)1/?$ $1 [R=301,L]

#Categories
RewriteRule ^([a-zA-Z\_\-]+/([a-zA-Z\_\-]*/)?)(\d+)/?$ category.php?slug=$1&page=$3 [NC,L]
RewriteCond %{REQUEST_URI} !((oc-admin)|(oc-content)|(oc-includes)|(oc-installer)).*
RewriteRule ^([a-zA-Z\_\-\s\%]+)$ $1/
RewriteCond %{REQUEST_URI} !((oc-admin)|(oc-includes)|(oc-content)|(oc-installer)).*
RewriteRule ^([a-zA-Z\_\-]+/[a-zA-Z\_\-]*?)/?$ category.php?slug=$1&page=1 [NC,L]

ErrorDocument 404 /index.php?action=errorPage&code=404
ErrorDocument 500 /index.php?action=errorPage&code=500
</IfModule>


You should modify "/oc/" with whatever is your path to your OSClass folder

ljhelbo

  • Newbie
  • *
  • Posts: 20
Re: Installation problems
« Reply #10 on: October 17, 2010, 12:12:59 am »
Yes, I'll do that.

And then I tried to change '<?=' to '<?php echo' (only in the oc-admin/themes/modern/header.php file) and that was really it. Now my admin-panel not only works, now it also looks great  ;)

ljhelbo

  • Newbie
  • *
  • Posts: 20
Re: Installation problems
« Reply #11 on: October 17, 2010, 12:20:03 am »
Yes, now it works.

However, it may also have worked before  ;D

Only, I now realise that I was only able to see half of the admin-panel, so I had no idea that I had to make a .htaccess-file. That part of the page was not visible.

_CONEJO

  • Administrator
  • Hero Member
  • *****
  • Posts: 4689
Re: Installation problems
« Reply #12 on: October 17, 2010, 12:29:52 am »
Whops! My bad. We miss to include the .htaccess file in the .zip package! I re-uploaded the files, Thanks!!

ljhelbo

  • Newbie
  • *
  • Posts: 20
Re: Installation problems
« Reply #13 on: October 17, 2010, 10:35:36 am »
Well, we are definitely moving forward, but i still miss something - I think.

In the admin-panel, if I click on Items/manage items or Categories/manage categories, I believe all existing Items/Categories/Currencies etc. should be listed?

In all those places I only get the dropdown menu with Bulk action etc.

ljhelbo

  • Newbie
  • *
  • Posts: 20
Re: Installation problems
« Reply #14 on: October 17, 2010, 02:07:55 pm »
Yes, there is a problem. I have tried to narrow it down and found this. I click on Items/manage items in the admin panel. I found that themes/modern/items/index.php is loaded; but it seems as if the large script function in the first part of the file is not executed. I believe this is, what should show the existing items?

Unfortunately this kind of programming is a bit too high for me  :-[

Is it JavaScript?