chrometweaks.org

How to fix iPage Email "Remote host said: 550. User account is unavailable" Error?

Click Here To View All Answers...


Quick question: How to fix iPage Email "Remote host said: 550. User account is unavailable" Error? Thanks in advance for any response. Second question.. Hi all,.

Im (trying..) making a "shop" for resellers. I have disabled so that nobody (but me.

) can register users and so on.. This far I really like the way osCommerce is build. Even for me who aint good with code it's quite easy to modificate it the way you want it!.

Though I have run into an issue that I would appreciate some help with, and yes, I cant do it without some help from a codeing guru...

I would like the prices in my shop to be "disabled" until you login, is this possible and how hard would it be to make this more than fiction? ( this because I would like resellers to see what we are offering but they have to apply for reseller before they can see the prices we offer. ).

Thanx in advance for any points of views and (perhaps) some help with the codeing!..

Comments (134)

Good question... I dunno what is the right answer to your question. I'll do some investigation and get back to you if I got an useful answer. You should email the people at iPage as they probably can help you..

Comment #1

Lots of usefull stuff on those pages! Recomend them to all of you! Does anyone have:loginviewprice2.zip who could send it to me? The download page was down so I couldnt download the file.....

Comment #2

In catalog/includes/classes/currencies.php... right down the bottom change:.

   function display_price($products_price, $products_tax, $quantity = 1) {.

     return $this->format(tep_add_tax($products_price, $products_tax) * $quantity);.

   }.

 }.

?>.

To:.

   function display_price($products_price, $products_tax, $quantity = 1) {.

   if (tep_session_is_registered('customer_id')){.

     return $this->format(tep_add_tax($products_price, $products_tax) * $quantity);.

   .

   } else {.

   .

     return ''; .

 }.

}.

}.

?>.

You may wish to hide the cart also... column_right.php.

 if (tep_session_is_registered('customer_id'))include(DIR_WS_BOXES'shopping_cart.php');.

And in catalog/shopping_cart.php, change:.

 require("includes/application_top.php");.

To:.

 require("includes/application_top.php");.

 .

   if (!tep_session_is_registered('customer_id')) {.

   $navigation->set_snapshot();.

   tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL'));.

 }..

Comment #3

Johnson, thank You so much for Your time!! I really appreciate it!.

Thank You very much! I would never had this thing working on my own!..

Comment #4

That's what I am here for....

BTW, where the code has:.

} else {.

Return '';.

}.

You *can* put something like:.

} else {.

Return 'Login for price';.

}.

This post has been edited by.

Johnson.

: 30 November 2003, 01:46..

Comment #5

Hide Prices.

Suggested code by Matti Ressler.

My install: modified MS2.

The code for catalog/shopping_cart.php returns an error message:.

"Parse error: parse error in \catalog\shopping_cart.php on line 16" (the "if"-line)..

I tried to run without the code for shopping_cart.php, but found that it is possible to add a product / buy and then view the price in the shopping cart..

Please help.....

Comment #6

Post some of your own file - the above code is correct - I suspect you may have an error in a line above the mod..

Matti..

Comment #7

Thanks for your reply. I'm very close to a B2B functionality of osC.....

The start of catalog/shopping_cart.php is.

<?php.

/*.

 $Id: shopping_cart.php,v 1.73 2003/06/09 23:03:56 hpdl Exp $.

 osCommerce, Open Source E-Commerce Solutions.

 http://www.oscommerce.com.

 Copyright (c) 2003 osCommerce.

 Released under the GNU General Public License.

*/.

  require("includes/application_top.php");.

 .

// Start "hide prices".

If (!tep_session_is_registered('customer_id')){.

$navigation->set_snapshot();.

Tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL'));.

}.

// Stop "hide prices".

 require(DIR_WS_LANGUAGES$language'/'FILENAME_SHOPPING_CART);.

 $breadcrumb->add(NAVBAR_TITLE, tep_href_link(FILENAME_SHOPPING_CART));.

?>.

<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">.

<html <?php echo HTML_PARAMS; ?>>.

<head>.

The error message refer to line 17 which is the "if"-line. Tell me if you need more code. Thanks again...

Comment #8

It looks fine - I would say you are pulling the error page from cache - clear your cache..

Matti..

Comment #9

Sorry,I don't think so. I cleared and got the same error. I've tried both an online test and on my PC, both with Opera and IE. The same thing happens..

Here is what I do:.

1. From the front page (where prices are hided) click on a product..

2. From product info page click on "add to Chart" button..

3. Error message......

How can I work to find find the source of the error? Any clues?.

Is it a lot of comlicated work to remove the "buy now" and "add to chart" buttons, when not logged in?.

(I can give you the link, if you want to see...).

This post has been edited by.

Blokke.

: 15 January 2004, 15:27..

Comment #10

I have been looging for a solution for hiding the prices for non-logged in users, I could not get the contribution to work, but this works great!!!!!.

You the Man!!!!!..

Comment #11

Hi, Richard!.

Good thing that you are successful with the code for hiding prices. I still have some problems. I even tried on a clean install and got the same error: "Parse error: parse error in \catalog\shopping_cart.php on line 16" (the "if"-line)..

What happens when not logged in and you try to add a product to the cart, or just try to look at the cart? That's when I get the error. I simply don't understand what's happening here........

Would appreciate your comments on this. Thanks!..

Comment #12

Hi All,.

I started to implement this feature on my, and recently noticed this thread, both of which applies the same logic..

However, one thing I have noticed in my own version, is when a guest customer is redirected to login page, once they login the cart is not automatically updated with the item that they had price-blindly selected. This I am now thinking might be irrating to customers who are registered but just doing a preliminary browse, so I am now considering removing the buy now buttons altogether..

But on an extended slightly similiar note, which might help to overcome the above, is there a way for to get osC to return the customer to the page that they were currently viewing when they clicked the buy now button and then logged in, which by default seems to be redirecting the customer to the main index page?..

Comment #13

For information.

I solved my problem in another way, by removing all the "buy now" and "add to cart" buttons when not logged in. As soon as a customers log in and are approved, he may see the prices. Seems to work well..

I never found out about my parse error problem.....

Thanks for help anyway...

Comment #14

Could you shed a little light on how you accomplished hiding the add to cart and checkout if user isnt logged in, and show the buttons when they are logged in. I really could use this code. thank you billyjack..

Comment #15

Hi!.

Sorry for my late answer, have been busy lately. Here is my solution to hide prices and hide buy buttons:.

Appendix A.

//start blokke "hide prices".

Hide Prices (simple code from forum) - ok 291203.

(.

Http://forums.oscommerce.com/index.php?sho...F%BDentry202205.

).

In catalog/includes/classes/currencies.php... right down the bottom change:.

Function display_price($products_price, $products_tax, $quantity = 1) {.

Return $this->format(tep_add_tax($products_price, $products_tax) * $quantity);.

}.

}.

?>.

To:.

Function display_price($products_price, $products_tax, $quantity = 1) {.

If (tep_session_is_registered('customer_id')){.

Return $this->format(tep_add_tax($products_price, $products_tax) * $quantity);.

} else {.

Return '';.

}.

}.

}.

?>.

Hide the cart also... column_right.php.

If (tep_session_is_registered('customer_id'))include(DIR_WS_BOXES'shopping_cart.php');.

Hide the spesials also... column_right.php.

If (tep_session_is_registered('customer_id'))include(DIR_WS_BOXES'specials.php');.

Suggested change in shoppingcart not done (forum)..

Remove "add to cart" buttons:.

\catalog\product_info.php.

Replace:.

               <td class="main" align="right">.

                  echo tep_draw_hidden_field('products_id', $product_info['products_id'])tep_image_submit('button_in_cart.gif', IMAGE_BUTTON_IN_CART); ?></td>.

With:.

               <td class="main" align="right"><?php if (tep_session_is_registered('customer_id')){.

                  echo tep_draw_hidden_field('products_id', $product_info['products_id'])tep_image_submit('button_in_cart.gif', IMAGE_BUTTON_IN_CART);.

                  }else{.

                  RETURN'Login for price';.

                  }?></td>.

/catalog/product_reviews_info.php.

Replace:.

 echo '<p><a href="'tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action'))'action=buy_now')'">'tep_image_button('button_in_cart.gif', IMAGE_BUTTON_IN_CART)'</a></p>';.

With:.

   if (tep_session_is_registered('customer_id')){.

 echo '<p><a href="'tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action'))'action=buy_now')'">'tep_image_button('button_in_cart.gif', IMAGE_BUTTON_IN_CART)'</a></p>';.

   }.

Blokke - remove "Buy now" buttons.

Catalog/index.php.

Line 128-147 is now like:.

   if (tep_session_is_registered('customer_id')){.

   $define_list = array('PRODUCT_LIST_MODEL' => PRODUCT_LIST_MODEL,.

                        'PRODUCT_LIST_NAME' => PRODUCT_LIST_NAME,.

                        'PRODUCT_LIST_MANUFACTURER' => PRODUCT_LIST_MANUFACTURER,.

                        'PRODUCT_LIST_PRICE' => PRODUCT_LIST_PRICE,.

                        'PRODUCT_LIST_QUANTITY' => PRODUCT_LIST_QUANTITY,.

                        'PRODUCT_LIST_WEIGHT' => PRODUCT_LIST_WEIGHT,.

                        'PRODUCT_LIST_IMAGE' => PRODUCT_LIST_IMAGE,.

                        'PRODUCT_LIST_BUY_NOW' => PRODUCT_LIST_BUY_NOW);.

    }else{.

    $define_list = array('PRODUCT_LIST_MODEL' => PRODUCT_LIST_MODEL,.

                        'PRODUCT_LIST_NAME' => PRODUCT_LIST_NAME,.

                        'PRODUCT_LIST_MANUFACTURER' => PRODUCT_LIST_MANUFACTURER,.

                        'PRODUCT_LIST_PRICE' => PRODUCT_LIST_PRICE,.

                        'PRODUCT_LIST_QUANTITY' => PRODUCT_LIST_QUANTITY,.

                        'PRODUCT_LIST_WEIGHT' => PRODUCT_LIST_WEIGHT,.

                        'PRODUCT_LIST_IMAGE' => PRODUCT_LIST_IMAGE);.

    }.

// end blokke "hide prices".

Hope this will help..

Regards Brynjar lokke as "blokke"..

Comment #16

Hi all,.

Im (trying..) making a "shop" for resellers. I have disabled so that nobody (but me.

) can register users and so on.. This far I really like the way osCommerce is build. Even for me who aint good with code it's quite easy to modificate it the way you want it!.

Though I have run into an issue that I would appreciate some help with, and yes, I cant do it without some help from a codeing guru...

I would like the prices in my shop to be "disabled" until you login, is this possible and how hard would it be to make this more than fiction? ( this because I would like resellers to see what we are offering but they have to apply for reseller before they can see the prices we offer. ).

Thanx in advance for any points of views and (perhaps) some help with the codeing!..

Comment #17

WOW!!!.

THANX A LOT MELTUS!!!.

Going to try it out right a way!.

Thank you really much again!!..

Comment #18


This question was taken from a support group/message board and re-posted here so others can learn from it.