Update WordPress Blog Location

On August 15, 2010, in Web, by Bikas

If your Blog is made on WordPress platform and you want to change the location/ URL of the Blog, which may be due to reasons like: your have built the site on your system locally using the localhost in your URL; or your blog is already hosted with different domain name and now you want to host it with some other domain name, this article may be of some use to you fellows. Just follow the few simple steps mentioned below.

  1. First of all logon to your Blog’s database through PhpMyAdmin control.
  2. Then select your Blog’s database. You will find 15-16 tables under it using the prefix “wp_”.
  3. Now you need to pass some queries for some of the tables; to be precise you need to pass some queries for three tables which are mentioned below:

First update wp_options table:

To update WordPress options with the new blog location, first select the wp_options table on the left panel. Then select “SQL” on the right panel  and pass the below mentioned query in the textbox for the query and click go to pass the query.

UPDATE wp_options SET option_value = replace(option_value, 'http://www.old-domain.com', 'http://www.new-domain.com') WHERE option_name = 'home' OR option_name = 'siteurl';

your old domain will be http://localhost/your_blog if you have built the site locally on your system.

Second update wp_posts table: This will fix URLs of the WordPress posts and pages, which translated from post slug, and stored in database wp_posts table as guid field. The URL values in this field are stored as absolute URLs, so we need to change them with the following SQL query:

UPDATE wp_posts SET guid = replace(guid, 'http://www.old-domain.com','http://www.new-domain.com');


Lastly update wp_posts table:
This will fix the URL links which you have used to link posts or pages internally within the posts you have published, which we will change using the following SQL query:

UPDATE wp_posts SET post_content = replace(post_content, 'http://www.old-domain.com', 'http://www.new-domain.com');

Now re-login to your wp-administration to update the cookies and also check your blog and post if they are working properly.

Tagged with:
 

Movies With Different Tastes

On August 11, 2010, in Movies, by pkmahanand

Movies are the kind of entertainment which we can enjoy alone or in a group. When I say “in a group” I should say “like minded group” instead. Like a brief discussion after a cricket match, a discussion after watching a movie also reduces the queries. When you are a moviegoer, you always want a place to discuss. It can be anyone but sadly movie goers always are isolated. A majority of the population thinks that movies are for entertainment and it has nothing to do with art. The art of story telling, or choreography or any other factor is overlooked by general audience.

Any movie with a different theme is regarded as an outclassed one. Only a few people who can think say it’s a creative one. I have heard many people saying this movie is bad that movie is good. How can that be justifiable? As Wilde said “there is no book as bad or good, they are either well written or badly written”. I say it exactly goes with movies too.
“There is no good movie or bad movie. Either it’s well made or poorly made.”

Months before I saw Stanley Kubrik’s Lolita. Most of my friends including me don’t have enough time and interest in books so we prefer movies adapted from books or classic literature. Lolita is also an adaptation one from Vladimir Nabokov’s book of same name. Most of my friends said they disliked the concept. Why???? Coz they couldn’t accept an older man seducing a far younger teenager girl. They thought it’s like pedophile. I am sure these kinds of people cause controversies when something with a different taste comes to the market. I don’t understand why they convict Prof Humbert of pedophile while they applause for Leon and Matilda’s relation.

It depends on the person’s sense of acceptance during the period of watching. Otherwise the same person liking Leon: The Professional can’t dislike movie like Lolita.

Film makers tell us a story. What matters is the way they tell us. Story and plot can be anything. If we consider Quentin Tarantino’s movies he never emphasizes his stories but characters and situations. The amount of tension went high when I showed some of my friends (not the same) Chan-wook Park’s Old Boy. Everyone asked me how a movie like this can have such a cult status and a place in the IMDb top list? I say what is wrong in that movie? Old Boy is one of the best movies made in history in my opinion. The plot contains materials of incest between Brother-sister and father-daughter. I know that’s is bad thing but the way Park told the story is brilliant. The actor’s portrayals of characters are unbeatable.

Just because we didn’t like a plot, it doesn’t give enough causes to hate that entire movie. We know that drug dealing and ruthless killing is also bad. Then why do we remember Tony Montana every time we talk about mafia movies????

People say movies are the face and voice of society. I strongly condemn it. LITERATURE is voice of society, not movie. The concept of changing society through cinema is a big failure. I have talked with numerous people whether they get any message from movies and the very common answer I got is “movies are supposed to entertain people. Who cares about the message” or “It happens in movies only”. Believing in miracles is a dream in real life. Since more than 50 years cinemas are giving message on Love. But what is the status of a loved couple in our society? Hated and outclassed? It surely indicates that message through movies don’t work.

Tagged with:
 

Recently I came upon a problem, which you guys must have already faced with is embedding a flash movie on to your site while supporting the web standards. While validating the site I got 7 validation errors and all of them was because I had embedded a Flash Movie to my site.

While searching for the fix, I came on to http://www.alistapart.com/articles/flashsatay/ whose solution really worked fine for me and I am really thankful to them. The solution is real easy and you can try for yourself following the steps mentioned below.

  1. First of all create a container flash file, exactly of the same height and width for the movie file you want to embed on your site. For example, if you want to embed a flash banner to your site and its width is 400px and height is 250px, your container movie’s width and height would be of 400px and 250px, respectively.Name the file c.fla. You can name it something else too; just for my convenience I am naming it c.fla
  2. on the first frame of the movie c.fla, write a script for calling your flash movie on to it, which will be something like the below:
    _root.loadMovie(“banner.swf”, “0”);

    flash script

    where banner.swf is your flash movie that you want to embed on your site.

  3. Now publish your container movie which in my case will be c.swf
  4. Now search for your flash embedded code that will be similar to the following:
    <script >
    AC_FL_RunContent( ‘codebase’,’http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0′,’width’,’400′,’height’,’250′,’title’,’Banner’,’src’,’banner’,’quality’,’high’,’pluginspage’,’http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash’,’wmode’,’transparent’,’movie’,’images/banner’ ); //end AC code
    </script>
    <noscript>
    <object classid=”clsid:D27CDB6E-AE6D-11cf-96B8-444553540000″ codebase=”http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0″ width=”400″ height=”250″ title=”Banner”>
    <param value=” banner.swf” />
    <param value=”high” />
    <embed src=” banner.swf” width=”400″ height=”250″ quality=”high” pluginspage=”http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash” wmode=”transparent”></embed>
    </object>
    </noscript>
  5. Now we will edit this code a little so that we get our desired result. Search for the code written between the <object>…</object> tags, which will be similar to-
    <object classid=”clsid:D27CDB6E-AE6D-11cf-96B8-444553540000″ codebase=”http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0″ width=”400″ height=”250″ title=”Banner”>
    <param value=” banner.swf” />
    <param value=”high” />
    <embed src=” banner.swf” width=”400″ height=”250″ quality=”high” pluginspage=”http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash” wmode=”transparent”></embed>
    </object>
  6. Edit the code to be something like below:
    <object data=”c.swf?path=movie.swf” width=”400″ height=”250″ title=”Banner”>
    <param value=”c.swf?path=movie.swf” />
    <param value=”high” />
    </object>
  7. Be sure to remove the <embed> … </embed> tags and whatever is between them. Your final code should be something like the below mentioned:
    <script >
    AC_FL_RunContent( ‘codebase’,’http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0′,’width’,’400′,’height’,’250′,’title’,’Banner’,’src’,’banner’,’quality’,’high’,’pluginspage’,’http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash’,’wmode’,’transparent’,’movie’,’images/banner’ ); //end AC code
    </script>
    <noscript>
    <object data=”c.swf?path=movie.swf” width=”400″ height=”250″ title=”Banner”>
    <param value=”c.swf?path=movie.swf” />
    <param value=”high” />
    </object>
    </noscript>
  8. Now you are ready to publish your site. Save the file and upload it along with the container movie that you created, in this case c.swf
  9. Check for validation.