Changing the ‘WordPress Address URL’ of your blog the hard way

Follow the steps shown here if you can no longer access the admin site of your wordpress blog.

If you have accidentaly (or stupidly 🙂 ) changed the WordPress Address of your blog to an incorrect value, you’ll find out that you can no longer access the admin console to change it back. To fix it you have two options:

  • Temporary PHP change
  • Direct database change

Continue reading “Changing the ‘WordPress Address URL’ of your blog the hard way”

Redirect using PHP

Tutorial on PHP redirection.

Redirecting using PHP is very simple. You just need a single line of code in your php page. I’ll split it out to two lines in the example below for the sake of clarity. Create a text file, calling it redirect.php. Add the following content to it:

$URI = $_REQUEST['to'];
Header ("Location: $URI");

In the above example, we use the ‘to‘ parameter to specify our target URI.

To use this in your pages your link would look like the following:

<a href="">Visit</a>

You’d obviously replace with your own domain, or you can omit it if you are referring it from the same domain.

Make sure there are no spaces or line-breaks before the <?php. If you are modifying the HTTP header, you are not allowed to write the the stream before that line.

connecting to base from a form via macro

How to access your base database within a form.

Base is the database package that comes with 2.x. It seems quite OK as a desktop database package. But, I’ve found that resources for macro editing in basic for base are quite scarce. This is quite a problem since the editor it comes with doesn’t have intellisense/autocomplete. The uno documentation is way too big to be of any real use as a reference document. So I thought I’ll just write a beginners tutorial for connecting to the base database that is currently open from a form using basic macro. Continue reading “connecting to base from a form via macro”