The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Cleaning up PHP layout problem....HELP!
albertg
post Oct 7 2008, 08:11 AM
Post #1





Group: Members
Posts: 6
Joined: 2-October 08
Member No.: 6,797



I have a page layout issue I have been been pulling my hair out for 6 hours. I'm not sure if its a CSS issue or an HTML. I need the "Location" and "Show Only" column to move to the right. The header is a graphic that I will then extend to match. If anyone has any suggestions I would really appreciate it. Here is a link to a screenshot of the formatting problem: http://swrtx.com/images/formatting_issue.jpg

Here is the PHP thtml code for the page:

<?
$nav = NULL;
if ( isset( $userInfo ) )
{
echo $profile->showUserinfo( $userInfo['User'], $userInfo['User']['is_employer']);
$nav = $userInfo['User']['is_employer'];
}
else
{
$box = $this->requestAction( '/text_pages/getText/7', array( 'return' => true ) );
echo "<div class=\"content\">";
echo "<h2><img src=\"/img/arrow.gif\" /> ".$box['TextPage']['title']."</h2>";
echo $box['TextPage']['body'];
echo "</div>";
}
echo $profile->userNav($nav);
$skillChapters = $this->requestAction( "/skill_chapters/getSkillChapters", array( "return"=>true ) );
?>
<div class="contenttop">
<h2><img src="/img/arrow.gif" /> Search Jobs</h2>
<?
echo $form->create( 'Job', array( 'action' => 'index' ) )."\n";
echo "<div class=\"row\">";
echo "<div class=\"floatThird\">";
echo "<div class=\"floatClear\">";
echo "<label>Skill Set</label>";
foreach ($skillChapters as $skillChapter)
{
$currid = $skillChapter['SkillChapter']['id'];
echo "<div class=\"selectSkill\">";
echo "<div class=\"floatLeft\" onclick=\"showHide('showchapter".$currid."', 'showRightMinus".$currid."', 'showRightPlus".$currid."')\">".$skillChapter['SkillChapter']['title']."</div>";
echo "<div class=\"floatRight\" onclick=\"showHide('showchapter".$currid."', 'showRightMinus".$currid."', 'showRightPlus".$currid."')\">";
echo "<span class=\"showElement\" id=\"showRightPlus".$currid."\">+</span><span class=\"hideElement\" id=\"showRightMinus".$currid."\">(close)</span>";
echo "</div>";

$skillCategories = $skillChapter['SkillCategory'];
echo "<div class=\"hideSkillBox\" id=\"showchapter".$currid."\">";
$iteration =0;
foreach ($skillCategories as $idx=>$skillCategory)
{
echo (($idx !=0) && ($idx%3 ==0) ) ? '<hr>' : '';
echo "<div class=\"skillset\">";

echo "<div class=\"skillCategory\">";
echo $skillCategory['title'];
echo "</div>";
$skills = $skillCategory['Skill'];
foreach ($skills as $skill)
{
$skillid = $skill['id'];
$skillIds[] = array("skill".$skill['id'],$skill['title'],$skillChapter['SkillChapter']['title']);
echo "<div class=\"skillRow\">";
echo "<input type=\"checkbox\" name=\"data[Job][skill".$skillid."]\" value=\"1\" id=\"skill".$skillid."\"> ";
echo "<label for=\"skill".$skillid."\">{$skill['title']}</label>";
echo "</div>";
}
echo "</div>";

$iteration++;
}
echo "</div>";
echo "</div>";
}
echo "<p class=\"error-message\">".$errormessage."</p>";
echo "</info>";
echo "</div>";
echo '<script type="text/javascript">';
echo 'var SKILLS = [';
for ($i=0; $i < count($skillIds); $i++) {
echo '["'.$skillIds[$i][0].'","'.$skillIds[$i][1].'","'.$skillIds[$i][2].'"]';
if ($i < count($skillIds)-1) {
echo ",";
}
}
echo '];';
echo '</script>';
echo "<div id='selectedSkills' style='display:none;'></div>";
echo "<div class=\"floatClear\">";
echo "<div id=\"skillsbox\" class=\"hideElement\">";
echo "<div class=\"floatLeft\">";
$curr = 0;
foreach ( $skillsArr as $index => $skill )
{
if ($curr % $percols == 0)
{
echo "</div><div class=\"floatLeft\">";
}
echo "<div class=\"checkbox\"><input type=\"checkbox\" name=\"data[Job][skill".$index."]\" value=\"1\" id=\"Job".$skill."\"> ".$skill."</div>";
$curr++;
}
echo "</div>";
echo "</div>";
echo "</div>";
echo "</div>";

echo "<div class=\"floatThird\">";
echo "<div class=\"floatClear\">";

echo "<label>Location</label>";
echo $form->input( 'country', array( 'label'=> false, 'type'=>'select', 'options'=> array( 'United States' => 'United States' ) ) );

$state = null;
if ( !empty( $this->data['Job']['state'] ) )
{
$state = $this->data['Job']['state'];
}

echo $profile->stateSelector( $state, 'data[Job][state]','zipfinder_state' );

if ( !empty( $this->data['Job']['city'] ) )
{
$city = $this->data['Job']['city'];
echo '<div id="zipfinder_city_div"><select name="data[Job][city]" id="zipfinder_city"><option value="">Any City</option>';
$cities = '';
foreach ($cityRecords as $index => $record)
{
$cities .= "<option value=\"{$record['zipcodes']['city']}\">{$record['zipcodes']['city']}</option>\n";
}
$cities = str_replace( "value=\"$city\"", "selected=\"selected\" value=\"$city\"", $cities );
echo $cities;
echo '</select></div>';
}
else
{
echo '<div id="zipfinder_city_div"><select name="data[Job][city]" id="zipfinder_city"><option value="">---</option></select></div>';
}


/*
if ( !empty( $this->data['Job']['zip'] ) )
{
$city = $this->data['Job']['city'];
$zip = $this->data['Job']['zip'];

echo '<div id="zipfinder_zipcode_div"><select name="data[Job][zip]" id="zipfinder_zipcode"><option value="">Any Zip Code</option>';
$zips = '';
foreach ($zipRecords as $index => $record)
{
$zips .= "<option value=\"{$record['zipcodes']['zipcode']}\">{$record['zipcodes']['zipcode']}</option>\n";
}
$zips = str_replace( "value=\"$zip\"", "selected=\"selected\" value=\"$zip\"", $zips );
echo $zips;
echo '</select></div>';
}
else
{
echo '<div id="zipfinder_zipcode_div"><select name="data[Job][zip]" id="zipfinder_zipcode"><option value="">---</option></select></div>';
}
*/

$ajaxOptions['url'] = '/zipcodes/jobZipFinder/city';
$ajaxOptions['update'] = 'zipfinder_city_div';
echo $ajax->observeField( 'zipfinder_state', $ajaxOptions );

//$ajaxOptions['url'] = '/zipcodes/jobZipFinder/zipcode';
//$ajaxOptions['update'] = 'zipfinder_zipcode_div';
//echo $ajax->observeField( 'zipfinder_city', $ajaxOptions );

echo $form->input( 'zip', array( 'label' => 'or Zip Code', 'maxlength' => 5 ) );

echo "</div>";
echo "<div class=\"floatClear\">";
echo $form->input( 'distance', array( 'label' => 'Distance within', 'type'=>'select', 'options'=> array( '' => 'Any Distance', '40' => '40 Miles', '80' => '80 Miles', '100' => '100 Miles' ) ) );
echo "</div>";
echo "<div class=\"floatClear\">";
echo $form->input( 'posted', array( 'label' => 'Posted within', 'type'=>'select', 'options'=> array( '' => 'Any Time', '30' => '30 Days', '60' => '60 Day', '90' => '90 Day' ) ) );
echo "</div>";
echo "</div>";

echo "<div class=\"floatThird\">";
echo "<h4 class=\"marBot\">Show only:</h4>";
echo "<div class=\"checkbox\"><input type=\"checkbox\" name=\"data[Job][full_time]\" value=\"1\" id=\"JobFull-time\"><label for=\"JobFull-time\">Full-Time</label></div>";
echo "<div class=\"checkbox\"><input type=\"checkbox\" name=\"data[Job][part_time]\" value=\"1\" id=\"JobPart-time\"><label for=\"JobPart-time\">Part-Time</label></div>";
echo "<div class=\"checkbox\"><input type=\"checkbox\" name=\"data[Job][contract]\" value=\"1\" id=\"JobContract\"><label for=\"JobContract\">Contract</label></div>";
echo "<div class=\"checkbox\"><input type=\"checkbox\" name=\"data[Job][telecommute]\" value=\"1\" id=\"JobTelecommute\"><label for=\"JobTelecommute\">Telecommute</label></div>";
echo "<h4 class=\"filter\">Filter by:</h4>";
echo "<div class=\"checkbox\"><input type=\"checkbox\" name=\"data[Job][sponsorship]\" value=\"1\" id=\"JobSponsorship\"><label for=\"JobSponsorship\">Provides Sponsorship</label></div>";
echo "</div>";
echo "<div class=\"button buttonLeft floatClear\"><input type=\"submit\" value=\"Search\" /></div>";
echo '<p>Didn\'t find your skill set? <a href="/users/contact">Click here to submit a new skill set.</a></p>';

echo "</div>";
echo "</form>";





?>
</div>

This post has been edited by albertg: Oct 7 2008, 08:36 AM
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Darin McGrew
post Oct 7 2008, 10:51 AM
Post #2


WDG Member
********

Group: Root Admin
Posts: 8,365
Joined: 4-August 06
From: Mountain View, CA
Member No.: 3



Can you provide the URL (address) of a document that demonstrates the problem?
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
albertg
post Oct 7 2008, 01:43 PM
Post #3





Group: Members
Posts: 6
Joined: 2-October 08
Member No.: 6,797



I'm not at liberty to post a link to the app per confidentially of the client. However, I will create a dev environment w/o client info and then post it up.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 25th April 2024 - 11:49 PM