SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    SitePoint Enthusiast
    Join Date
    Nov 2003
    Location
    austalia
    Posts
    59
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Can I install the wordpress database tables into my existing site database

    I wish to install a wordpress blog onto an existing site and integrate the design into the site.

    The current site has a database that I'm using for a range of functions. Can this DB also be used for the wordpress blog or does that software require a dedicated/separate database?

    Also can anyone point me in the direction of useful content about integrating the standard wordpress interface into an existing site. I guess something the addresses modifying default styles etc.

    It would be great if anyone could help with this.

    Appreciate any thoughts.

    Thanks

  2. #2
    Follow Me On Twitter: @djg gold trophysilver trophybronze trophy Dan Grossman's Avatar
    Join Date
    Aug 2000
    Location
    Philadephia, PA
    Posts
    20,580
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    You can use your existing database without problems, it doesn't need its own. WordPress's appearance is defined by themes which you have full control over.

  3. #3
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Basically to integrate your design, you just take the HTML markup that surrounds the text content of your web page and place it around the code that generates the WP content from the database.

    Though instead of it all being in one file, it is split up into various files that stitch together to make a single webpage
    1. one for the header (the top of your HTML file)
    2. the sidebar (the side column of your HTML file)
    3. the footer (the bottom of your HTML file)
    These 3 files are used on every page

    Then (depending on the theme) there are a series of files that are used for the main content area of your web page and are used conditionally based on what part of the site you are viewing
    1. the front page (index.php)
    2. the archives page(s) (archives.php)
    3. a page (page.php)
    4. a single blog post (single.php)
    and so on... These files are all primarily the same, though they are/can be made to display content differently they all contain The Loop.

    There are a few more files in a theme that are fairly self explanatory once you see the titles of them (look at other themes for a good start) Then depending on the layouts requirements you can create additional files for various sections of the site.

    It is really quite simple, once you get used to it.

    This explanation was quite brief, need more help, just ask, or seek more thorough advice

  4. #4
    SitePoint Member
    Join Date
    Dec 2008
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Dan Grossman View Post
    You can use your existing database without problems, it doesn't need its own. WordPress's appearance is defined by themes which you have full control over.
    Hi there.. can you tell me the procedure to use existing databse for wordpress ?

  5. #5
    SitePoint Addict antirem's Avatar
    Join Date
    Dec 2008
    Posts
    292
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You can merge them.. but i suggest doing it by hand and keeping backups.

  6. #6
    Programming Since 1978 silver trophybronze trophy felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, NSW, Australia
    Posts
    16,825
    Mentioned
    25 Post(s)
    Tagged
    1 Thread(s)
    Simply select an appropriate prefix for the tables so you know what WordPress blog they belong to. The rest of the values in the config file then just need to be set to the same values that the rest of your scripts using the same database are using. All these values can be entered when you run the install script and will add all the needed tables to your existing database.

    I have a couple of WordPress blogs sharing a database with a range of other services running on my site - you just need to make sure that there are no duplicated table names and different prefixes for each takes care of that.
    Stephen J Chapman

    javascriptexample.net, Book Reviews, follow me on Twitter
    HTML Help, CSS Help, JavaScript Help, PHP/mySQL Help, blog
    <input name="html5" type="text" required pattern="^$">


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
  •