Results 1 to 13 of 13

Thread: Installing two versions of Contao on localhost

  1. #1
    User
    Join Date
    05-12-14.
    Posts
    72

    Default Installing two versions of Contao on localhost

    Hi,

    I do not know if what I am doing is advised.
    I have Contao 2.11.11 installed on localhost and I want to start the process of migrating to Contao v3.x.

    So (on mac) i have 2.11 installed in Sites.

    I have therefore created a sub directory named Contao3 and dropped the Contao 3.2 files into that.

    Now, when i try to run the contao 3 installer, the first message i get is:

    Modify files via FTP
    Your server does not support file access via PHP; most likely PHP runs as Apache module under a different user. Therefore please enter your FTP login details, so Contao can modify files via FTP (Safe Mode Hack).



    So how can i avoid this message and just install contao3?? Or should i really not install it next to contao2?

    Muchos appreciatos.

  2. #2
    User
    Join Date
    05-12-14.
    Posts
    72

    Default

    Ah wait, the same permission issue solved this.


    BUT, the question still stands really for me:

    Should i install two different versions of contao in essentially the same folder on localhost, even though one version is in a subfolder?
    Of course, i reference a different sql database, so i can't see any problem in doing this, but one of you might tell me different.


    Actually, i only get so far with the install tool until i get the message:

    Web installer

    There is a Contao installation already. Are you looking for the Live Update?


    So, is there a possible solution to installing two different versions of contao on localhost?

    Cheers
    Last edited by markclaus; 06/16/2014 at 15:24.

  3. #3
    User
    Join Date
    05-12-14.
    Posts
    72

    Default

    Ok, so, talking to myself again, I managed to get the install tool to start running for version 3 on localhost. Im running this under MAMP at the moment, so i can distinguish between the two Contao versions.

    It all goes well unto a certain point.

    When i get to updating the tables i get a whole bunch of errors:

    Deprecated notice: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in system/modules/core/library/Contao/Database/Mysql.php on line 58
    #0 [internal function]: __error(8192, 'mysql_connect()...', '/Applications/M...', 58, Array)
    #1 system/modules/core/library/Contao/Database/Mysql.php(58): mysql_connect('localhost:8889', 'root', 'root')
    #2 system/modules/core/library/Contao/Database.php(77): Contao\Database\Mysql->connect()
    #3 system/modules/core/library/Contao/Database.php(161): Contao\Database->__construct(Array)
    #4 [internal function]: Contao\Database::getInstance()
    #5 system/modules/core/library/Contao/System.php(122): call_user_func(Array)
    #6 contao/install.php(488): Contao\System->import('Database')
    #7 contao/install.php(183): InstallTool->setUpDatabaseConnection()
    #8 contao/install.php(1148): InstallTool->run()
    #9 {main}

    Warning: Cannot modify header information - headers already sent by (output started at /Applications/MAMP/htdocs/contao3/system/helper/functions.php:70) in system/modules/core/library/Contao/Template.php on line 261
    #0 [internal function]: __error(2, 'Cannot modify h...', '/Applications/M...', 261, Array)
    #1 system/modules/core/library/Contao/Template.php(261): header('Vary: User-Agen...', false)
    #2 system/modules/core/classes/BackendTemplate.php(121): Contao\Template->output()
    #3 contao/install.php(858): Contao\BackendTemplate->output()
    #4 contao/install.php(215): InstallTool->outputAndExit()
    #5 contao/install.php(1148): InstallTool->run()
    #6 {main}

    Warning: Cannot modify header information - headers already sent by (output started at /Applications/MAMP/htdocs/contao3/system/helper/functions.php:70) in system/modules/core/library/Contao/Template.php on line 262
    #0 [internal function]: __error(2, 'Cannot modify h...', '/Applications/M...', 262, Array)
    #1 system/modules/core/library/Contao/Template.php(262): header('Content-Type: t...')
    #2 system/modules/core/classes/BackendTemplate.php(121): Contao\Template->output()
    #3 contao/install.php(858): Contao\BackendTemplate->output()
    #4 contao/install.php(215): InstallTool->outputAndExit()
    #5 contao/install.php(1148): InstallTool->run()
    #6 {main}








    Although I am also getting told by the installation tool that i have successfully installed version 3.2. When i goto the backend to login, on the login page i get:

    Deprecated notice: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in system/modules/core/library/Contao/Database/Mysql.php on line 58
    #0 [internal function]: __error(8192, 'mysql_connect()...', '/Applications/M...', 58, Array)
    #1 system/modules/core/library/Contao/Database/Mysql.php(58): mysql_connect('localhost:8889', 'root', 'root')
    #2 system/modules/core/library/Contao/Database.php(77): Contao\Database\Mysql->connect()
    #3 system/modules/core/library/Contao/Database.php(161): Contao\Database->__construct(Array)
    #4 [internal function]: Contao\Database::getInstance()
    #5 system/modules/core/library/Contao/System.php(122): call_user_func(Array)
    #6 system/modules/core/library/Contao/User.php(89): Contao\System->import('Database')
    #7 system/modules/core/classes/BackendUser.php(103): Contao\User->__construct()
    #8 system/modules/core/library/Contao/User.php(151): Contao\BackendUser->__construct()
    #9 [internal function]: Contao\User::getInstance()
    #10 system/modules/core/library/Contao/System.php(122): call_user_func(Array)
    #11 contao/index.php(49): Contao\System->import('BackendUser', 'User')
    #12 contao/index.php(129): Index->__construct()
    #13 {main}

    Warning: Cannot modify header information - headers already sent by (output started at /Applications/MAMP/htdocs/contao3/system/helper/functions.php:70) in system/modules/core/library/Contao/Template.php on line 261
    #0 [internal function]: __error(2, 'Cannot modify h...', '/Applications/M...', 261, Array)
    #1 system/modules/core/library/Contao/Template.php(261): header('Vary: User-Agen...', false)
    #2 system/modules/core/classes/BackendTemplate.php(121): Contao\Template->output()
    #3 contao/index.php(121): Contao\BackendTemplate->output()
    #4 contao/index.php(130): Index->run()
    #5 {main}

    Warning: Cannot modify header information - headers already sent by (output started at /Applications/MAMP/htdocs/contao3/system/helper/functions.php:70) in system/modules/core/library/Contao/Template.php on line 262
    #0 [internal function]: __error(2, 'Cannot modify h...', '/Applications/M...', 262, Array)
    #1 system/modules/core/library/Contao/Template.php(262): header('Content-Type: t...')
    #2 system/modules/core/classes/BackendTemplate.php(121): Contao\Template->output()
    #3 contao/index.php(121): Contao\BackendTemplate->output()
    #4 contao/index.php(130): Index->run()
    #5 {main}





    I enter the admin details and password, and i get:

    Deprecated notice: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in system/modules/core/library/Contao/Database/Mysql.php on line 58
    #0 [internal function]: __error(8192, 'mysql_connect()...', '/Applications/M...', 58, Array)
    #1 system/modules/core/library/Contao/Database/Mysql.php(58): mysql_connect('localhost:8889', 'root', 'root')
    #2 system/modules/core/library/Contao/Database.php(77): Contao\Database\Mysql->connect()
    #3 system/modules/core/library/Contao/Database.php(161): Contao\Database->__construct(Array)
    #4 [internal function]: Contao\Database::getInstance()
    #5 system/modules/core/library/Contao/System.php(122): call_user_func(Array)
    #6 system/modules/core/library/Contao/User.php(89): Contao\System->import('Database')
    #7 system/modules/core/classes/BackendUser.php(103): Contao\User->__construct()
    #8 system/modules/core/library/Contao/User.php(151): Contao\BackendUser->__construct()
    #9 [internal function]: Contao\User::getInstance()
    #10 system/modules/core/library/Contao/System.php(122): call_user_func(Array)
    #11 contao/index.php(49): Contao\System->import('BackendUser', 'User')
    #12 contao/index.php(129): Index->__construct()
    #13 {main}

    Warning: Cannot modify header information - headers already sent by (output started at /Applications/MAMP/htdocs/contao3/system/helper/functions.php:70) in system/modules/core/library/Contao/Template.php on line 261
    #0 [internal function]: __error(2, 'Cannot modify h...', '/Applications/M...', 261, Array)
    #1 system/modules/core/library/Contao/Template.php(261): header('Vary: User-Agen...', false)
    #2 system/modules/core/classes/BackendTemplate.php(121): Contao\Template->output()
    #3 contao/index.php(121): Contao\BackendTemplate->output()
    #4 contao/index.php(130): Index->run()
    #5 {main}

    Warning: Cannot modify header information - headers already sent by (output started at /Applications/MAMP/htdocs/contao3/system/helper/functions.php:70) in system/modules/core/library/Contao/Template.php on line 262
    #0 [internal function]: __error(2, 'Cannot modify h...', '/Applications/M...', 262, Array)
    #1 system/modules/core/library/Contao/Template.php(262): header('Content-Type: t...')
    #2 system/modules/core/classes/BackendTemplate.php(121): Contao\Template->output()
    #3 contao/index.php(121): Contao\BackendTemplate->output()
    #4 contao/index.php(130): Index->run()
    #5 {main}






    Now, I am no coder, so don't really understand whats going on here.
    Any help would be greatly appreciated.

  4. #4
    User
    Join Date
    05-12-14.
    Posts
    72

    Default

    Gets stranger.

    So after a bunch of errors, i close the browser, reopen, and direct to the contao/index.php and now i get no errors, although it is running in maintenance mode and internal cache has not yet been built.

    But so far it appears to be working. As it is only a local version running of course, I am not so bothered. I will now start to migrate and see what happens.

  5. #5
    User
    Join Date
    05-12-14.
    Posts
    72

    Default

    So, I had contao 3.2 installed, but due to trying to keep the extensions (assets are they called in 3?) i removed 3.2 and installed version 3.0.6 instead.
    that went fine until i started to import the DB and templates.
    Which has thrown the site design way off. This is ok i guess, i can rebuild it, like the million dollar man, it can be rebuilt:D

    So I am going to post things, as they come up, that i can't figure out. Hopefully someone might chime in and help out whilst i try to figure it out myself.

    So, the first thing I cannot figure out is:

    Navigation shows the 'Skip Navigation', which i read somewhere can be removed from the mod_navigation.tpl (/system/modules/frontend/templates) file. Things is i don't see a mod_navigation.tpl (/system/modules/frontend/templates) anywhere. So where do i remove it, or where is this .tpl file?



    Ahhh, ok i found which file i needed to update to remove 'Skip Navigation'. This was found in /system/modules/core/templates/mod_navigation.xhtml


    So now i move on to other site elements. The CSS is not being read correctly for whatever reason. Certain page elements have been shunted from where they should be to where they should not be. The pages where not centred, text is wrapping all of a sudden, lots of things need fixing all of a sudden.
    Last edited by markclaus; 06/17/2014 at 11:41.

  6. #6
    User
    Join Date
    05-12-14.
    Posts
    72

    Default

    Ok, i have the pages centred. I had to uncheck 'Static Layout' in Page Layouts --> Edit layouts, then check it again.
    I get the impression there might be quiet a lot of this deactivating/reactivating of elements to get stuff back to how it was.

    The problem i want to resolve now is that my article text in the main column is wrapping when reducing the browser windows width.

    Im guessing its some kind of block overflow issue or something.

    Any ideas anyone?

    The other things at the moment is that my newslist shows, 'Currently there are no news items.' which i do not want to be displayed. I was thinking there would be something in the mod_newslist.xhtml file, but i don't see anything to remove to prevent that from showing. (FIXED) - modified the mod_newsarchive_empty.xhtml file.
    However, my full news archive is not showing for some reason. (FIXED) - I had to re-establish the links for the articles to the newsarchive.

    Lastly, for the time being, change language is not showing for some reason. My sites default language is german, but its just the english version that is showing by default, and I don't see any way to fix that as yet. (FIXED) - Had to reinstall the change language extension to get that to work.


    Just got to figure this text wrapping malarchy

    Its very quiet in the international contao forums.......forums.........forums..........forums
    Last edited by markclaus; 06/17/2014 at 15:39.

  7. #7
    User
    Join Date
    07-23-10.
    Posts
    86

    Default

    Its very quiet in the international contao forums.......
    If you respond your Questions on your own, nobody will comment. We just give you time to find it out your self

    Seriously, if you have a complete new topic, you should open a new question in a suitable section.

    But you are right, the international Community is not so active as the German one, or if it is in a specific language, they have build up a own community.

  8. #8
    User
    Join Date
    05-12-14.
    Posts
    72

    Default

    Quote Originally Posted by ciaobello View Post
    If you respond your Questions on your own, nobody will comment. We just give you time to find it out your self
    --- Yea I was getting that impression. I tend to use this place as a way to order my thoughts But thanks for answering, even if not answering the question.

    Quote Originally Posted by ciaobello View Post
    Seriously, if you have a complete new topic, you should open a new question in a suitable section.
    - Well, normally i would start a new topic by opening a new question. However as I am installing a new version and updating a contao site, it seemed appropriate to post these things in Installation & Updates. As its an ongoing topic to get the old website functioning in the same way in a newer contao version, it seems right to make a thread, rather than post here there and everywhere

    Quote Originally Posted by ciaobello View Post
    But you are right, the international Community is not so active as the German one, or if it is in a specific language, they have build up a own community.
    Is there an unofficial English speaking contao community besides this one here??

  9. #9
    User
    Join Date
    07-23-10.
    Posts
    86

    Default

    No ... other languaes than english ...

    https://contao.org/en/team.html, check out the ambassadors.

  10. #10
    User
    Join Date
    07-23-10.
    Posts
    86

    Default

    I tend to use this place as a way to order my thoughts
    Ok, just read the Ruls of the Forum and try to follow them. If everyone uses this place as a notebook, soon we will have a big mess.
    Just think of others, with a nice formulated question on the right place you already can help someone else if it is documented after solving.

  11. #11
    User Andreas's Avatar
    Join Date
    07-11-09.
    Location
    Mönchengladbach
    Posts
    499

    Default

    Quote Originally Posted by markclaus View Post
    ...Should i install two different versions of contao in essentially the same folder on localhost, even though one version is in a subfolder?...
    You never should install an installation to servers root. Else it's like installing Photoshop to
    C:\Program Files\
    But you install it to
    C:\Program Files\Photoshop\
    You can install as many installations as you like
    ROOT/_c2_my/
    ROOT/_c32_my/
    ROOT/_c33_my/
    Give each folder a subdomain
    c2.example.org
    c32.example.org
    c33.example.org
    and direct them to the appropriate folder.

    There's an english IRC-channel named #contao.

    ps Keep your questions simple and rtfms
    Web-Development, Freelancer, Burgtech, XHTML, HTML5, CSS, PHP, Javascript, MooTools, MySQL and more
    Amazon wishlist

  12. #12
    User
    Join Date
    05-12-14.
    Posts
    72

    Default

    Quote Originally Posted by Andreas View Post
    You never should install an installation to servers root. Else it's like installing Photoshop to
    C:\Program Files\
    But you install it to
    C:\Program Files\Photoshop\
    You can install as many installations as you like
    ROOT/_c2_my/
    ROOT/_c32_my/
    ROOT/_c33_my/
    Give each folder a subdomain
    c2.example.org
    c32.example.org
    c33.example.org
    and direct them to the appropriate folder.

    There's an english IRC-channel named #contao.

    ps Keep your questions simple and rtfms

    Thanks for the pointer to the IRC channel.

    What about installing one version to ~user/Sites and the other into MAMP/htdocs.........would that be ok? I mean, thats what I've done. Works ok.
    Last edited by markclaus; 06/18/2014 at 10:16.

  13. #13
    Community-Moderator xchs's Avatar
    Join Date
    06-19-09.
    Posts
    1,287

    Default

    If it works it should be okay
    Contao Community Moderator
    → Support options

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •