Do you have a different connection file for live versus local? You normally only get this error when the values referenced on these lines is not in the connection file that is included at the top of the page. If you have different connection files for the live versus the local you will need to update one or the other so that the connection file itself is the same, but the values used in it differ.
For example, if you have a different host, username, password, or db value in the connection file you should update the version you are working with to have the correct values in it. Normally the file just makes use of the values that were entered into the wizard, so if you set it up locally but now want it to be on a live server you will need to update the information that is in this connection file.