Undeleting an entire Database?

2006-04-25 Thread clint lenard
Hey guys,

 Well, I was unable to find anything on Google and I don't expect to find a
miracle... but I figured why not.

On Sunday morning I was trying to delete a Table through PHPMyAdmin and
well... I dropped the entire DB without backing it up before. Stupid
mistake, I know.

So, I'm using Fedora Core OS/Linux and I was wondering if there was any way
to undelete this db? I lost about 350 new members on my site + all kinds of
blogs, comments, messages, etc. Is there ANY way to get this info back? If
not, It's not a huge deal... I suppose. I just wanted to see if anyone might
know of any special ways to get some of the data back.

Thanks!

- Clint Lenard


Need help with a Basic Query.

2006-03-08 Thread clint lenard
Hey Guys,

  I was wondering if I could get some assistance with building a
Simple Import Script using PHP and MySQL. Basically I'm trying to pull
info out of one Table and Insert it into the other Table.

Can anyone show me a simple example of this? I can figure out how to
do the rest if I had a simple example.

Thanks!

- Clint

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: users are always the last to know :-)

2005-10-07 Thread clint lenard
Interesting

On 10/7/05, Hassan Schroeder [EMAIL PROTECTED] wrote:
 FYI, from the Silicon Valley Business Journal:


 Oracle buys Finnish open source company

 Oracle Corp. said Friday it has bought Innobase OY, a software company
 based in Finland, for an undisclosed price.

 Innobase makes open source database software. Its product, InnoDB, runs
 on the MySQL database system, also an open source software system.
 Oracle said it has long supported open source software, which is freely
 available to anyone who wants to build on it or improve it, and said it
 plans to add more to open source systems in the future.

 Redwood Shores-based Oracle (NASDAQ: ORCL) said it plans to negotiate to
 extend the deal between Innobase and MySQL when it needs to be renewed
 next year.

 http://www.bizjournals.com/sanjose/stories/2005/10/03/daily52.html?hbx=e_du

 --
 Hassan Schroeder - [EMAIL PROTECTED]
 Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com

   dream.  code.



 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: HTML in MySQL?

2005-09-12 Thread clint lenard
Hey Douglass,

Curious about using Smarty (taking the Crash Course and bookmarked a couple 
of other tut's)... One of the advantages of using a DB to store the HTML 
Sites was the opportunity to give the user an automated Zip file of their 
site if they wanted to download it and create their own site (domain) with 
it at any time... can this be done with Smarty? Like I said - I've used 
Smarty before - but only through a program called Jamroom - and it's 
basically using their Variables for their program - and it was limited.

So, my main concern is - if the User wanted to download their site and have 
their own copy to upload to another domain - would it be possible to do 
this? Sorry, my mind is tired along with my eyes... I guess I'm still not 
100% sure how Smarty works!

Thanks,

Clint

On 9/12/05, clint lenard [EMAIL PROTECTED] wrote:
 
 Douglass, thanks for the tips!
 
 As far as Mambo or Xoops - I wanted to create something a little different 
 - but I WAS thinking of using Smarty before-hand... I just wasn't sure how I 
 could really use it? I'm familiar with Smarty as far as I've played around 
 with it a little... but I guess I wasn't sure how I could use it in this 
 situation... are you saying that I should have Smarty hold the design - and 
 use MySQL to populate the Virtual Sites with the Content stored in the DB? 
 
 
 It sounds like a great Idea and would probably be much more Resource 
 friendly! This is why I asked for more info and gave more info - hoping NOT 
 to get someone to code anything - but to give me Ideas on what would work 
 the best. :)
 
 Thanks alot for the info Douglass! I'm going to search the web for more 
 Tutorials on Smarty - hopefully I find something related to this! It'd 
 probably make my life much easier if what I think you're saying is what 
 you're actually saying lol
 
 On 9/12/05, [EMAIL PROTECTED]  [EMAIL PROTECTED] 
 wrote:
  
  clint lenard wrote:
  
  Hi guys, I'm fairly new to MySQL and I've searched for about a week looking 
  for an answer to this...
  
  I'm trying to design a Database that would hold HTML sites in the DB itself 
  and use PHP to call for the HTML file - which would be populated with 
  Content from another table in MySQL. I was told I could put HTML into 
  MySQL... so my main question would be: is this possible?, is this a BAD 
  thing? but most of all... would this be resource intensive?
  
  Thanks for any answers! I hope I'm using this list correctly - I did search 
  Google and I've been reading an MySQL Manual for over a week now trying to 
  get it down 110%!
  
  Thanks,
  
  Clint
  
 
  If you would like, you may check out these related technologies that do 
  what you are talking about already:
  
  www.mamboserver.com http://www.mamboserver.com
  www.xoops.com http://www.xoops.com
  
  Also, if you use templates, it makes it easy to just keep the relevant 
  parts of the page, and then display them inside of a predefined template. 
  That way, you can change the template whenever you want, and all your pages 
  will change. If you store the part of the HTML that formats the text 
  (color, 
  style etc) in the DB, this isn't possible.
  
  smarty.php.net http://smarty.php.net
  
  wasn't sure if you could use any of these, but, here's the info. 
  
  -- 
  http://www.douglassdavis.com
  
  



Re: HTML in MySQL?

2005-09-12 Thread clint lenard
can anyone help me with this question?

On 9/12/05, clint lenard [EMAIL PROTECTED] wrote:
 
 Hey Douglass,
 
 Curious about using Smarty (taking the Crash Course and bookmarked a 
 couple of other tut's)... One of the advantages of using a DB to store the 
 HTML Sites was the opportunity to give the user an automated Zip file of 
 their site if they wanted to download it and create their own site (domain) 
 with it at any time... can this be done with Smarty? Like I said - I've used 
 Smarty before - but only through a program called Jamroom - and it's 
 basically using their Variables for their program - and it was limited.
 
 So, my main concern is - if the User wanted to download their site and 
 have their own copy to upload to another domain - would it be possible to do 
 this? Sorry, my mind is tired along with my eyes... I guess I'm still not 
 100% sure how Smarty works!
 
 Thanks,
 
 Clint
 
 On 9/12/05, clint lenard [EMAIL PROTECTED] wrote:
  
  Douglass, thanks for the tips!
  
  As far as Mambo or Xoops - I wanted to create something a little 
  different - but I WAS thinking of using Smarty before-hand... I just wasn't 
  sure how I could really use it? I'm familiar with Smarty as far as I've 
  played around with it a little... but I guess I wasn't sure how I could use 
  it in this situation... are you saying that I should have Smarty hold the 
  design - and use MySQL to populate the Virtual Sites with the Content 
  stored in the DB? 
  
  It sounds like a great Idea and would probably be much more Resource 
  friendly! This is why I asked for more info and gave more info - hoping NOT 
  to get someone to code anything - but to give me Ideas on what would work 
  the best. :)
  
  Thanks alot for the info Douglass! I'm going to search the web for more 
  Tutorials on Smarty - hopefully I find something related to this! It'd 
  probably make my life much easier if what I think you're saying is what 
  you're actually saying lol
  
  On 9/12/05, [EMAIL PROTECTED]  [EMAIL PROTECTED] 
  wrote:
   
   clint lenard wrote:
   
   Hi guys, I'm fairly new to MySQL and I've searched for about a week 
   looking 
   for an answer to this...
   
   I'm trying to design a Database that would hold HTML sites in the DB 
   itself 
   and use PHP to call for the HTML file - which would be populated with 
   
   Content from another table in MySQL. I was told I could put HTML into 
   MySQL... so my main question would be: is this possible?, is this a 
   BAD 
   thing? but most of all... would this be resource intensive?
   
   
   Thanks for any answers! I hope I'm using this list correctly - I did 
   search 
   Google and I've been reading an MySQL Manual for over a week now trying 
   to 
   get it down 110%!
   
   Thanks,
   
   Clint
   
   
 

   If you would like, you may check out these related technologies that 
   do what you are talking about already:
   
   www.mamboserver.com http://www.mamboserver.com
   www.xoops.com http://www.xoops.com
   
   Also, if you use templates, it makes it easy to just keep the relevant 
   parts of the page, and then display them inside of a predefined template. 
   That way, you can change the template whenever you want, and all your 
   pages 
   will change. If you store the part of the HTML that formats the text 
   (color, 
   style etc) in the DB, this isn't possible.
   
   smarty.php.net http://smarty.php.net
   
   wasn't sure if you could use any of these, but, here's the info. 
   
   -- 
   http://www.douglassdavis.com
   
   
  



Re: HTML in MySQL?

2005-09-11 Thread clint lenard
Wow, thanks for all of the Information guys! I've learned alot and now I've 
actually been doing more brain storming... I've been reading all of these 
emails over and over - and they're helping me understand more!

What I'm trying to do is save User Sites in MySQL and use PHP to pull them 
out through the Database using a Virtual Directory (if that's what it could 
be called?) like: http://mysite,com/bob-in-germany or just 
http://mysite,com/bobingermany/

There may be a ton of these sites as time moves on and I'm just trying to 
make sure I learn as much as I can before I get a major problem on my 
hands... I know it may be resource intensive - but it just seems to be 
easier to delete unused sites through a DB rather than a File System I may 
not have full control over?

Anyways, Thanks again guys! This is helping alot! anymore feedback would be 
great!

- Clint

P.S. - Sorry Jasper for sending it to you and not the list... I'm new to 
GMail :(

On 9/11/05, Jasper Bryant-Greene [EMAIL PROTECTED] wrote:
 
 Jasper Bryant-Greene wrote:
  John Trammell wrote:
 
  $input = This is br the \n input; # value from user
  $saved = This is br the br input; # value in database
  $recovered = This is \n the \n input; # retrieved from db, != $input
 
 
  Please don't top-post. That is the perfect argument for not applying
  nl2br() before saving the information in the database. It should be done
  *when outputting* instead.
 
  ?php
  $in = mysql_real_escape_string(This is br the \n input);
  mysql_query(INSERT INTO my_table (my_field) VALUES ('$in'));
 
  $array =mysql_fetch_assoc(mysql_query(SELECT my_field FROM my_table));
  print(nl2br($array['my_field']));
  ?
 
  works exactly as intended.
 
 
 Oh, and I should mention you probably want to htmlspecialchars() that
 data too, if you actually want to see the br and if you want to
 protect from XSS attacks etc.
 
 --
 Jasper Bryant-Greene
 Freelance web developer
 http://jasper.bryant-greene.name/
 
 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]
 



Re: HTML in MySQL?

2005-09-11 Thread clint lenard
Douglass, thanks for the tips!

As far as Mambo or Xoops - I wanted to create something a little different - 
but I WAS thinking of using Smarty before-hand... I just wasn't sure how I 
could really use it? I'm familiar with Smarty as far as I've played around 
with it a little... but I guess I wasn't sure how I could use it in this 
situation... are you saying that I should have Smarty hold the design - and 
use MySQL to populate the Virtual Sites with the Content stored in the DB? 


It sounds like a great Idea and would probably be much more Resource 
friendly! This is why I asked for more info and gave more info - hoping NOT 
to get someone to code anything - but to give me Ideas on what would work 
the best. :)

Thanks alot for the info Douglass! I'm going to search the web for more 
Tutorials on Smarty - hopefully I find something related to this! It'd 
probably make my life much easier if what I think you're saying is what 
you're actually saying lol

On 9/12/05, [EMAIL PROTECTED] [EMAIL PROTECTED] 
wrote:
 
 clint lenard wrote:
 
 Hi guys, I'm fairly new to MySQL and I've searched for about a week looking 
 for an answer to this...
 
 I'm trying to design a Database that would hold HTML sites in the DB itself 
 and use PHP to call for the HTML file - which would be populated with 
 Content from another table in MySQL. I was told I could put HTML into 
 MySQL... so my main question would be: is this possible?, is this a BAD 
 thing? but most of all... would this be resource intensive?
 
 Thanks for any answers! I hope I'm using this list correctly - I did search 
 Google and I've been reading an MySQL Manual for over a week now trying to 
 get it down 110%!
 
 Thanks,
 
 Clint
 

 If you would like, you may check out these related technologies that do 
 what you are talking about already:
 
 www.mamboserver.com http://www.mamboserver.com
 www.xoops.com http://www.xoops.com
 
 Also, if you use templates, it makes it easy to just keep the relevant 
 parts of the page, and then display them inside of a predefined template. 
 That way, you can change the template whenever you want, and all your pages 
 will change. If you store the part of the HTML that formats the text (color, 
 style etc) in the DB, this isn't possible.
 
 smarty.php.net http://smarty.php.net
 
 wasn't sure if you could use any of these, but, here's the info. 
 
 -- 
 http://www.douglassdavis.com
 



HTML in MySQL?

2005-09-09 Thread clint lenard
Hi guys, I'm fairly new to MySQL and I've searched for about a week looking 
for an answer to this...

I'm trying to design a Database that would hold HTML sites in the DB itself 
and use PHP to call for the HTML file - which would be populated with 
Content from another table in MySQL. I was told I could put HTML into 
MySQL... so my main question would be: is this possible?, is this a BAD 
thing? but most of all... would this be resource intensive?

Thanks for any answers! I hope I'm using this list correctly - I did search 
Google and I've been reading an MySQL Manual for over a week now trying to 
get it down 110%!

Thanks,

Clint


Re: HTML in MySQL?

2005-09-09 Thread clint lenard
Thanks Jasper for the info! This may sound stupid - but I just want to be 
sure... do I need to strip the slashes and special characters out and add 
them when they're called... or..? I'm just trying to get a clear picture 
of exactly what needs to be done with this particular job...

thanks!

On 9/9/05, Jasper Bryant-Greene [EMAIL PROTECTED] wrote:
 
 clint lenard wrote:
  Hi guys, I'm fairly new to MySQL and I've searched for about a week 
 looking
  for an answer to this...
 
  I'm trying to design a Database that would hold HTML sites in the DB 
 itself
  and use PHP to call for the HTML file - which would be populated with
  Content from another table in MySQL. I was told I could put HTML into
  MySQL... so my main question would be: is this possible?, is this a 
 BAD
  thing? but most of all... would this be resource intensive?
 
 Of course -- HTML is just a string like any other. Just use a TEXT field
 of the appropriate size for the size of your HTML pages, and then store
 the HTML as a string in that field. Then retrieve it and output the
 string with PHP.
 
 --
 Jasper Bryant-Greene
 Freelance web developer
 http://jasper.bryant-greene.name/
 
 If you find my advice useful, please consider donating to a poor
 student! You can choose whatever amount you think my advice was
 worth to you. http://tinyurl.com/7oa5s
 
 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]
 



Re: HTML in MySQL?

2005-09-09 Thread clint lenard
David and Jasper - thank you both! I will play around with this more now 
that you have explained my biggest questions!

Thanks guys,

Clint

:-)

On 9/9/05, Jasper Bryant-Greene [EMAIL PROTECTED] wrote:
 
 clint lenard wrote:
  Thanks Jasper for the info! This may sound stupid - but I just want to
  be sure... do I need to strip the slashes and special characters out and
  add them when they're called... or..? I'm just trying to get a clear
  picture of exactly what needs to be done with this particular job...
 
 If you're using PHP, you need to run mysql_real_escape_string() on any
 string data that is going into MySQL. This will handle escaping and
 special characters for you, and there is no need to unescape it when
 retrieving it from the DB.
 
 See http://www.php.net/mysql_real_escape_string
 
 HTH
 --
 Jasper Bryant-Greene
 Freelance web developer
 http://jasper.bryant-greene.name/
 
 If you find my advice useful, please consider donating to a poor
 student! You can choose whatever amount you think my advice was
 worth to you. http://tinyurl.com/7oa5s
 
 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]