Balance Lookup Instructions
Here are two ways to have your customers check their balances
from your website.
The first is the simplest, and requires no coding. The second allows far more customization and has no identification from StickyStreet shown,
but requires access to the files system of your web server and PHP to be installed there, as well as some minor HTML code editing.
If that's a blank stare or a look of horror in your face right now, use the
first optio and don't even look at option 2. If instead that's a twinkle in your
eyes and a grin from ear to ear, skip option 1 and go straight to the instructions to option
2.
In either case, there are some customization options that you have to request from the support desk: - Whether to show the customers Name, Email, or Phone Number.
- Whether to show the transaction history at all, or just show the amount earned or redeemed without details.
- Whether to show the rewards available
(make sure to include your company name or Account ID with your request.)
Option 1
The simplest and quickest option.
Simply create a link on your site to the following URL:
http://www.rewardspixie.com/index.php?a=XXX
Where "XXX" is
your account owner's User ID that you use to login to StickyStreet (but not
your password. Keep that one safe!) Your customers will then be able to enter
their account number on the screen this links to, and then see their balance(s).
That's all!
If you want to get fancier, you can add the following customization. In the sample URL below:
- The language: Replace AAA in the URL below with the two-letter language code of one of the languages StickyStreet has available.
- The Decimal Separator: Replace BBB with either a comma ( , ) to make the decimal a comma, and the thousands separator a period.
- To only return a Balance for a campaign, replace CCC with the campaign name. Make sure to replace any spaces in the campaign name with the code: %20
- To use your own custom CSS definition file, replace DDD with the full URL of where your CSS file is.
http://www.rewardspixie.com/index.php?a=XXX&lang=AAA&sep=BBB&balance_only=CCC&css=DDD
Not every option is required. So for example if you just want to have the balance lookup in Spanish with the comma as the thousands separator, it would look like this:
http://www.rewardspixie.com/index.php?a=youraccountid&lang=ES&sep=,
Option 2
Gives you much more control, but you need to have certain abilities, or know
someone who does, and your website needs to fit certain requirements.
| Also, it's key that the PHP configuration has the "allow_url_fopen" setting to "on" to allow your server to fetch the balance information from our server. Contact your server administrator if you are unsure, but likely it is set the way you need. |
There are only two requirements.
- The first is that you have the ability to add files to your server (through FTP or some other method,)
- The second is that the server where your site is hosted has PHP enabled. The vast majority of Web servers do, and it will be unusual for it not to.
If neither requirements can be met, please use option 1,
above. If using a content management tool like Joomla, Mambo, or Drupal, include
both following steps as separate files inside a Wrapper or iFrame.
For Option 2, the process is pretty simple, and takes two
steps:
1) The first step is to create
a new page on your site where the results will be shown. Name it with a .php extension (not .html) For example: "check_code.php". Make sure that
the content area is at least 550 pixels wide (it likely is.) Place the following
HTML code where content would normally go:
<?php $code = $_POST['code']; $url = "http://www.scanandgorewards.com/balance.php?code=$code&account_id=XXX"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "$url"); curl_setopt($ch, CURLOPT_HEADER, false); curl_exec($ch); curl_close($ch); ?>
Where "XXX" is
your Account ID (Account owner's User ID).
2) The second step is to
place the following Form on a page of your Web site for customers to enter
their card code or unique identifier:
<form action="check_code.php" method="post" name="rewards_form"> Account Number: <input type="text" name="code" size="24" maxlength="255" border="0"> <input type="submit" name="code_submit_button" value="Look It Up" border="0"> </form>
Replace "check_code.php" with
the filename of the file from step 1-- if you named it differently. Save and
upload the changed files to your server-- they should both be on the same directory.
That's all.
Your customers will now be able to check their balances from within your Web
site!
If you want to get fancier, you can add the following customization.
- The language: Replace AAA in the code below with the two-letter language code of one of the languages StickyStreet has available.
- The Decimal Separator: Replace BBB with either a comma ( , ) to make the decimal a comma, and the thousands separator a period.
- To only return a Balance for a campaign, replace CCC with the campaign name. Make sure to replace any spaces in the campaign name with the code: %20
- To use your own custom CSS definition file, replace DDD with the full URL of where your CSS file is.
<?php $code = $_POST['code']; $url = "http://www.scanandgorewards.com/balance.php?code=$code&account_id=XXXXX"; $url .= "&lang=AAA"; $url .= "&sep=BBB"; $url .= "&balance_only=CCC"; $url .= "&css=DDD"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "$url"); curl_setopt($ch, CURLOPT_HEADER, false); curl_exec($ch); curl_close($ch); ?>
|