I really need some help here please.
I attempted to modify the default search param to properly reflect my website: http://yoursalonsday.com/search_home.php
I did this because the search was not producing any results when I had them at the default which included; sex, LookingFor, Country and Age. The following represents what the pHP search files were and what I tried to modify them to, but it is still not working. I am trying to add the following fields:
- RelationshipStatus
- ProfileType
- Ethnicity
- City
- State
- Zip
search.php
Before:
// default params for search form
$aDefaultParams = array(
'LookingFor' => isset($_GET['LookingFor']) ? $_GET['LookingFor'] : ($aProfile['Sex'] ? $aProfile['Sex'] : 'male'),
'Sex' => isset($_GET['Sex']) ? $_GET['Sex'] : ($aProfile['LookingFor'] ? $aProfile['LookingFor'] : 'female'),
'Country' => isset($_GET['Country'][0]) ? $_GET['Country'][0] : ($aProfile['Country'] ? $aProfile['Country'] : getParam('default_country')),
'DateOfBirth' => isset($_GET['DateOfBirth']) ? $_GET['DateOfBirth'] : getParam('search_start_age') . '-' . getParam('search_end_age'),
'Tags' => isset($_GET['Tags']) ? $_GET['Tags'] : '',
'online_only' => isset($_GET['online_only']) ? $_GET['online_only'] : '',
'photos_only' => isset($_GET['photos_only']) ? $_GET['photos_only'] : ''
);
After
// default params for search form
$aDefaultParams = array(
''LookingFor' => isset($_GET['LookingFor']) ? $_GET['LookingFor'] : ($aProfile['Sex'] ? $aProfile['Sex'] : 'male'),
'Sex' => isset($_GET['Sex']) ? $_GET['Sex'] : ($aProfile['LookingFor'] ? $aProfile['LookingFor'] : 'female'),
'Profiletype' => isset($_GET['ProfileType'][0]) ? $_GET['ProfileType'][0] : ($aProfile['ProfileType'] ? $aProfile['ProfileType'] : getParam('default_profileType')),
'Ethnicity' => isset($_GET['Ethnicity'][0]) ? $_GET['Ethnicity'][0] : ($aProfile['Ethnicity'] ? $aProfile['Ethnicity'] : getParam('default_ethnicity')),
'RelationshipStatus' => isset($_GET['RelationshipStatus'][0]) ? $_GET['RelationshipStatus'][0] : ($aProfile['RelationshipStatus'] ? $aProfile['RelationshipStatus'] : getParam('default_relationshipStatus')),
'City' => isset($_GET['City'][0]) ? $_GET['City'][0] : ($aProfile['City'] ? $aProfile['City'] : getParam('default_city')),
'State' => isset($_GET['State'][0]) ? $_GET['State'][0] : ($aProfile['State'] ? $aProfile['State'] : getParam('default_state')),
'Zip' => isset($_GET['Zip'][0]) ? $_GET['Zip'][0] : ($aProfile['Zip'] ? $aProfile['Zip'] : getParam('default_zip')),
'Country' => isset($_GET['Country'][0]) ? $_GET['Country'][0] : ($aProfile['Country'] ? $aProfile['Country'] : getParam('default_country')),
'DateOfBirth' => isset($_GET['DateOfBirth']) ? $_GET['DateOfBirth'] : getParam('search_start_age') . '-' . getParam('search_end_age'),
'Tags' => isset($_GET['Tags']) ? $_GET['Tags'] : '',
'online_only' => isset($_GET['online_only']) ? $_GET['online_only'] : '',
'photos_only' => isset($_GET['photos_only']) ? $_GET['photos_only'] : ''
);
Search_home.php
Before
// default params for search form
$aDefaultParams = array(
'LookingFor' => $aProfile['Sex'] ? $aProfile['Sex'] : 'male',
'Sex' => $aProfile['LookingFor'] ? $aProfile['LookingFor'] : 'female',
'Country' => $aProfile['Country'] ? $aProfile['Country'] : getParam('default_country'),
'DateOfBirth' => getParam('search_start_age') . '-' . getParam('search_end_age'),
);
After
// default params for search form
$aDefaultParams = array(
'LookingFor' => $aProfile['Sex'] ? $aProfile['Sex'] : 'male',
'Sex' => $aProfile['LookingFor'] ? $aProfile['LookingFor'] : 'female',
'Profiletype' => $aProfile['Profiletype'] ? $aProfile['Profiletype'] : getParam('default_profiletype'),
'Ethnicity' => $aProfile['Ethnicity'] ? $aProfile['Ethnicity'] : getParam('default_ethnicity')
'RelationshipStatus'=> $aProfile['RelationshipStatus'] ? $aProfile['RelationshipStatus'] : getParam('default_relationshipStatus')
'City' => $aProfile['City'] ? $aProfile['City'] : getParam('default_city'),
'State' => $aProfile['State'] ? $aProfile['State'] : getParam('default_state'),
'Zip' => $aProfile['Zip'] ? $aProfile['Zip'] : getParam('default_zip'),
'Country' => $aProfile['Country'] ? $aProfile['Country'] : getParam('default_country'),
'DateOfBirth' => getParam('search_start_age') . '-' . getParam('search_end_age'),
);
Please Help