formatting query results

Discussion in 'PHP' started by hendkandeel, Mar 1, 2009.

  1. #1
    I made a page takes its contents from my sql DB

    these data was written in MS Word as paragraphs , i copied it and paste into my sql table.

    when i made a query to shoe them (in php) it displayed without formatting !!

    how to show it formatted into paragraphs as its initial shape in MS Word?
     
    hendkandeel, Mar 1, 2009 IP
  2. indi.anupam

    indi.anupam Peon

    Messages:
    4
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    ah I think you are new to PHP or perhaps DB or programming..

    How can you store the MS-Word formatting styles in a DB table so that it would replicate itself when you extract/show it through some PHP script.. :eek:

    You should use some CSS styles for formatting and HTML+PHP mix code to show the data in a format you like (in which your word file is maybe)..
     
    indi.anupam, Mar 1, 2009 IP
  3. hendkandeel

    hendkandeel Peon

    Messages:
    52
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Yes, sir
    I am new to php
    would you give me another clue ?
     
    hendkandeel, Mar 1, 2009 IP
  4. hendkandeel

    hendkandeel Peon

    Messages:
    52
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Hey!!
    I tested a thing and it worked
    I wrote HTML paragraph code inside mysql table !
    It worked
     
    hendkandeel, Mar 1, 2009 IP
  5. crivion

    crivion Notable Member

    Messages:
    1,669
    Likes Received:
    45
    Best Answers:
    0
    Trophy Points:
    210
    Digital Goods:
    3
    #5
    what about integrating tinymce? its like ms word but in html/js/ajax
     
    crivion, Mar 1, 2009 IP
  6. SmartTechCracker

    SmartTechCracker Peon

    Messages:
    2
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    You need to use Rich Text editors like htmlarea, tinymce etc. which inherently do that formatting stuff for you and it gets displayed in exactly the manner you saw it in MS Word. I can help you get going on this if you require any help.
     
    SmartTechCracker, Mar 1, 2009 IP
  7. hendkandeel

    hendkandeel Peon

    Messages:
    52
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #7
    Thanks SmartTechCracker, but I didn't understand what you mean !

    Dear,crivion:
    what is "integrating tinymce? its like ms word but in html/js/ajax "
     
    hendkandeel, Mar 18, 2009 IP
  8. crivion

    crivion Notable Member

    Messages:
    1,669
    Likes Received:
    45
    Best Answers:
    0
    Trophy Points:
    210
    Digital Goods:
    3
    #8
    tiny mce is a nice tool which will look just like Microsoft Word
    check demo here
     
    crivion, Mar 18, 2009 IP
  9. hendkandeel

    hendkandeel Peon

    Messages:
    52
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #9
    Thanks I will read it
    your blog is so nice
     
    hendkandeel, Mar 18, 2009 IP
  10. crivion

    crivion Notable Member

    Messages:
    1,669
    Likes Received:
    45
    Best Answers:
    0
    Trophy Points:
    210
    Digital Goods:
    3
    #10
    thanks , its not looking trendy but content is valuable
    cheers
     
    crivion, Mar 18, 2009 IP