Welcome to the JaguarPC Community
JaguarPC
Sales: (888) 338-5261
Support: (888)-551-3050
Results 1 to 6 of 6

This is a discussion on How to get around account name in database? in the Shared & Semi-Dedicated forum
I'm trying to install tasks and it says to create a database named "tasks" and use the mysqldump provided. I cannot create a database named ...

  1. #1
    Aletia Customer
    Join Date
    Oct 2001
    Posts
    631

    How to get around account name in database?

    I'm trying to install tasks and it says to create a database named "tasks" and use the mysqldump provided. I cannot create a database named "tasks", as cpanel always adds my account name and an underscore to the beginning. How do I modify the script so that it will connect to the correct database? Also, how do I import the mysqldump?

  2. #2
    Rogue Developer
    Join Date
    Oct 2002
    Posts
    193

    Re: How to get around account name in database?

    I'm assuming you're using the 1.0 release... if not, you might have to play a little with these intructions.

    How do I modify the script so that it will connect to the correct database?
    In database.php on line 11, change the "tasks" in the mysql_select_db function to your actual database name. Say, "accountname_tasks". That oughta do it for everything.

    Also, how do I import the mysqldump?
    In SSH, cd to your tasks directory, and type the following command:

    mysql accountname_tasks -u accountname_databaseuser -p < install_tasks.sql

    Then enter your database user's password when prompted.

  3. #3
    Aletia Customer
    Join Date
    Oct 2001
    Posts
    631
    I found the following reference to the database "tasks" on line 7 of config.php

    PHP Code:
    $custom->table_name "tasks"// name of table used in database "tasks" 
    Should that line be edited to reflect the change as well?

    Also, how do you do that mysqldump in phpmyadmin?

    I also had a hard time following the instructions that were included with tasks. Would you mind making a step-by-step that's more clear?

    I appreciate the help Prone.

  4. #4
    the Windlord Gwaihir's Avatar
    Join Date
    Jun 2002
    Posts
    2,562
    Do I understand correctly that the 'mysqldump' is a file with all the MySQL commands to run? If so:

    In PHP MyAdmin select the right database and go to the tab 'SQL'. At the bottom you'll see the option "Or Location of the texfile:" Point to your dump from here and 'go'.
    Regards,

    Wim Heemskerk
    ---
    Visit MeCCG.net - Cardgaming in J.R.R. Tolkien's Middle-earth
    And Gwaihir.net - The Middle-earth CCG store

  5. #5
    Rogue Developer
    Join Date
    Oct 2002
    Posts
    193
    As for the other questions...

    Should that line be edited to reflect the change as well?
    No, I believe that's the name of a table within the database. They didn't exactly go out of their way to eliminate any ambiguity though...

    Would you mind making a step-by-step that's more clear?
    I've never used the package before so I can't speak from experience, but I'll take a stab at explaining everything


    Create a directory in your web document root or a virtual web directory to serve as the application root for "tasks". Put the contents of this zip file (maintaining the folder structure) into that directory.

    Make a directory under public_html called 'tasks', or whatever you'd like. Upload everything from the zip file there.


    Set your database settings in "database.inc".

    Make the above-mentioned change in database.php on line 11. change $db_user = "user"; to your database user name and $db_pass = "password; to the correct password.


    Create a database "tasks" in MySQL

    I gather you've got this one under control, although it'll be called "accountname_tasks", as reflected in database.php.


    Import the mysqldump "tasks_install.sql" into mysql.
    (at your prompt type "mysql tasks < tasks_install.sql" or use PHPMyAdmin or your favorite tool)


    As Gwaihir explained. One note: install_tasks.sql must be on your hard drive somewhere to do this from PHPMyAdmin.


    Set the proper values in "config.php" for your setup.

    Everything but $custom->enable_ical should be fine if you're not using iCalendar (set that to 0 in this case). If you are using it, leave that value as 1, and edit everything under // iCalendar integration settings, edit these as necessary.


    If you are going to use the PHP iCalendar integration, Make sure the tasks calendar file is writable by the web server.

    change the permissions of the file in question to 666 or 777.


    Optional: add index.php to your web server directory default pages

    I'm not certain on what that means, but I'm pretty sure it means that any files named index.php will be treated as a default page when accessing that directory from a web browser. So, for example, going to "http://your.domain.com/tasks/" will open index.php in there. In that case, this is already done.

    Hope that helps.

  6. #6
    Community Leader jason's Avatar
    Join Date
    Sep 2001
    Location
    Rochester, NY
    Posts
    6,003
    Originally posted by Prone
    Optional: add index.php to your web server directory default pages

    I'm not certain on what that means, but I'm pretty sure it means that any files named index.php will be treated as a default page when accessing that directory from a web browser. So, for example, going to "http://your.domain.com/tasks/" will open index.php in there. In that case, this is already done.

    Hope that helps. [/B]
    Correct, index.php is already an default document, so a file called index.php will load when you just go to "tasks/" in your browser. You can skip this step...

    --Jason
    Jason Pitoniak
    Interbrite Communications
    www.interbrite.com www.kodiakskorner.com

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
  •