Following your logic, something along the lines of...
$mgo=menu_get_object();
if ((isset($mgo) && $mgo->type=='TYPE') || $_GET['q']=='PATH') {
;
} else {
drupal_add_js(...);
}
...where you are doing your drupal_add_js(...) should do it. I think this does it cleaner, but it's late in the logic day here:
$mgo=menu_get_object();
if ((isset($mgo) && $mgo->type!='TYPE') && $_GET['q']!='PATH') {
drupal_add_js(...);
}
ADDITION:
$mgo=menu_get_object();
if (isset($mgo) && $mgo->type=='products') || strpos($_GET['q'], 'user/preference_center/ratings_reviews/')===0) {
; // do nothing
} else {
drupal_add_js(....);
}
will add js only if you are not looking at a product node or not in a path that starts with user/preference_center/ratings_reviews/ BUT please note that if what is after user/preference_center/ratings_reviews is a node, this won't work because that path is actually node/#, so you will have to then do...
$mgo=menu_get_object();
if (isset($mgo) && $mgo->type=='products') || strpos(drupal_get_path_alias(), 'user/preference_center/ratings_reviews/')===0) {
; // do nothing
} else {
drupal_add_js(....);
}
..instead.