Skip to content

Commit

Permalink
NEW design
Browse files Browse the repository at this point in the history
  • Loading branch information
andreyd22 committed May 29, 2010
1 parent 16e817c commit 872cabe
Show file tree
Hide file tree
Showing 15 changed files with 233 additions and 38 deletions.
25 changes: 25 additions & 0 deletions app/views/layouts/application.erb
@@ -0,0 +1,25 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title> harumambu.ru — Весь фриланс рунета, фрилансер, freelancer, freelance, free-lance, удаленная работа, телеработа, акуудфтсу, акуу-дфтсу, ahbkfyc, free-lance.ru, weblancer.net, dalance.ru, freelancer.ru</title>
<meta http-equiv="Content-type" content="text/html;charset=utf-8">
<meta name="keywords" content="фриланс freelancer freelance free lance фрилансер фри ланс телеработа работа на дому удаленная работа дизайн конкурс фриленс freelans freelanser job графика сайт заработок в интернете работа в сети домашний бизнес 1c верстка рисунок 3d фриленс">
<meta name="description" content="Harumambu.ru — Весь фриланс рунета, фрилансер, freelancer, freelance, free-lance, удаленная работа, телеработа, акуудфтсу, акуу-дфтсу, ahbkfyc, free-lance.ru, weblancer.net, dalance.ru, freelancer.ru">
<%= javascript_include_tag "jquery"%>
<%= javascript_include_tag "rails"%>
<%= javascript_include_tag "application"%>
<%= javascript_include_tag 'swfobject'%>
<%= javascript_include_tag 'jqModal'%>
<%= stylesheet_link_tag 'style','default'%>
<meta name = "csrf-token" content = "form_authenticity_token" >
<meta name = "csrf-param" content = "authenticity_token" >
<!--[if IE 6]>
<%= javascript_include_tag 'DD_belatedPNG'%>
<script>DD_belatedPNG.fix('.project, #projectop, #projecbottom');</script>
<![endif]-->
</head>
<body>
<%= yield %>
<!--LiveInternet counter--><script type="text/javascript">document.write("<a href='http://www.liveinternet.ru/click' target=_blank><img onload='this.style.display=\"none\"' src='//counter.yadro.ru/hit?t24.13;r" + escape(document.referrer) + ((typeof(screen)=="undefined")?"":";s"+screen.width+"*"+screen.height+"*"+(screen.colorDepth?screen.colorDepth:screen.pixelDepth)) + ";u" + escape(document.URL) +";i" + escape("Жж"+document.title.substring(0,80)) + ";" + Math.random() + "' border=0 width=88 height=15 alt='' title='LiveInternet: показано число посетителей за сегодня'><\/a>")</script><!--/LiveInternet-->
</body>
</html>
104 changes: 80 additions & 24 deletions app/views/projects/index.erb
@@ -1,32 +1,69 @@
<script type="text/javascript">
window.first_id = <%= session[:first_id].to_i %>;
</script>
<a name="top"></a>

<div id="loader"></div>
<div id="flashbanner"></div>
<div id="controls">
<form method="get" action="/">
<select name="strict" id="strict">
<option value="1">Найти</option>
<option value="0" <%= 'selected="selected"' if params[:strict] && params[:strict].to_i == 0 %>>Выделять</option>
</select> проекты, содержащие <input name="q" id="stop_words" value="<%= params[:q] %>" />
</form>
<input type="checkbox" <%= 'checked="checked"' if session[:new_window] %> onclick="$.post('/settings', { 'key' : 'new_window', 'value' : this.checked ? 1 : '' })" id="new_window" /> <label for="new_window">открыть ссылки в новом окне</label>
</div>

<div id="leftbl">

<div id="projects">
<%= will_paginate @projects %>
<% @projects.reverse.each do |project| %>
<div class="project" id="<%= project.id %>">
<div id="projectop"></div>
<h3><%=raw ( project.category != '' ? (project.category.title + ', ') : '' ) %><a href="<%= project.url %>"><%=raw project.title %></a></h3>
<p>Фриланс-проект: <%=raw project.desc %></p>
<div id="projectbottom"></div>
</div>
<% end %>
<%= will_paginate @projects %>
</div>
<div id="notifier">
<strong><a href="/">Харумамбу.ру</a></strong>
<p>Мы первыми собираем все фриланс-проекты интернета.</p>
<p>Если вам не хватает каких-то функций на сайте, <a href="javascript:;" onclick="$('#feedback').removeClass('invisible');$('#feedback_message').focus()">напишите нам</a>.</p>

</div>
<div id="loader"></div>

<div id="content">
<div id="ris"></div>
<div id="namelogo">
<a href="/">Харумамбу.ру</a>
<div id="logo_txt" style="text-decoration:none">
Мы первыми собираем все фриланс-проекты интернета.
</div>
</div>

<div id="search">
<form action="/" method="get">
<p>Поиск по объявлениям:</p>
<input name="q" type="text" value="<%= params[:q]%>" id="stop_words" style="width:260px;" />

<input name="" type="image" src="/images/arrow.gif" width="38" hspace="22" style="position: relative; top: 4px; left: 270px;" />
<br /><br /><p>
<input name="strict" type="radio" value="0" <%= 'checked="checked"' if params[:strict] && params[:strict].to_i == 0 %> />выделять
<input name="strict" type="radio" value="1" <%= 'checked="checked"' if (params[:strict] && params[:strict].to_i == 1 || !params[:strict]) %> />найти
<input type="checkbox" <%= 'checked="checked"' if session[:new_window] %> onclick="$.post('/settings', { 'key' : 'new_window', 'value' : this.checked ? 1 : '' })" id="new_window" /> <label for="new_window">открыть ссылки в новом окне</label>
<br><br><input type="checkbox" id="pause" /> <label for="pause">пауза</label>

</p>
<script>
$().ready(function() {

$('#categories').jqm({modal: true, trigger: '#categoriesTrigger'});
$('#sources').jqm({modal: true, trigger: '#sourcesTrigger'});
});
</script>


<p>
<a href="#" id="categoriesTrigger">Категории</a>
<a href="#" id="sourcesTrigger">Биржи</a>
<br/><br/>

</p>
</form>



<div id="categories" class="jqmWindow">
<form method="post" action="/categories">
<input type="hidden" name="redirect_to" value="<%= request.fullpath %>">
Expand All @@ -43,33 +80,52 @@
<center><input type="submit" value="Ок" /> <input type="button" class="jqmClose" value="Закрыть" /></center>
</form>
</div>
<div id="sources">
<input type="checkbox" id="pause" /> <label for="pause">пауза</label><br/><br/>
<a href="#" class="jqModal">Категории</a><br/><br/>

<div id="sources" class="jqmWindow">
<a href="javascript:;" onclick="$('input.source').each(function(e, elem){elem.checked=true})">Все</a>
<a onclick="$('input.source').each(function(e, elem){elem.checked=false})" href="javascript:;">Ни одной</a>
<br><br>
<form method="post" action="/sources">
<input type="hidden" name="authenticity_token" value="<%= form_authenticity_token %>"/>
<input type="hidden" name="redirect_to" value="<%= request.fullpath %>">
<div id="sources_list" style="height: 141px; width: 200px; overflow-y: auto">
<!--div id="sources_list" style="height: 141px; width: 200px; overflow-y: auto"-->
<div id="sources_list">
<% SOURCES.sort{|a,b| a.desc <=> b.desc}.each do |source| %>
<div><input class="source" type="checkbox" <%= want_source?(source.name) ? 'checked="checked"' : '' %> id="source_<%= source.name %>" name="sources[<%= source.name %>]" value="1" /> <label for="source_<%=source.name%>"><img src="/images/icons/<%= source.name.underscore %>.gif" align="absmiddle" /> <%= source.desc %></label></div>
<% end %>
</div>
<br/><a href="javascript:;" onclick="$('input.source').each(function(e, elem){elem.checked=true})">Все</a>
<a onclick="$('input.source').each(function(e, elem){elem.checked=false})" href="javascript:;">Ни одной</a><br/>
<br/><input type="submit" value="Применить" />

<div style="clear: both">&nbsp;</div>

<center><input type="submit" value="Применить" />
<input type="button" class="jqmClose" value="Закрыть" /></center>
</form>
<div id="twitter">
<a href="http://twitter.com/harumambu"><img src="/images/twitter.jpg" alt="" align="absmiddle" /></a>
</div>
</div>



<div id="feedback" class="invisible">
<h2>Написать</h2>
<% form_tag :feedback, :remote => true do |f| %>
<%= text_area_tag :feedback_message, @feedback.message, :class => "hover"%><br/>
<%= submit_tag 'Отправить' %>
<input type="button" value="Отменить" onclick="$('#feedback').addClass('invisible');$('#contacts_lnk').show()">
<% end %>
</div>


</div>


<div id="copyright">
На сайте чего-то не хватает? <a href="javascript:;" onclick="$('#feedback').removeClass('invisible');$('#feedback_message').focus()">напишите нам</a>.<br />
© 2010 Павел Голубев
<a href="http://twitter.com/harumambu"><img src="/images/twitter.jpg" alt="" align="absmiddle" /></a>

</div>

<div id="arrow" onClick="window.location='#top'" style="cursor:pointer"></div>

</div>

<script type="text/javascript">
Expand Down
Binary file added public/images/arrow.gif
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/arrow.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/bottom-message.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/bottom.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/middle-message.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/middle.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/ris.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/top-message.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/top.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 14 additions & 0 deletions public/javascripts/DD_belatedPNG.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 11 additions & 5 deletions public/javascripts/application.js
Expand Up @@ -2,6 +2,7 @@
// This file is automatically included by javascript_include_tag :defaults
//
$(document).ready(function(){

$(window).scroll(function(){
if ($(window).scrollTop() == $(document).height() - $(window).height()){
$('div#loader').html('<img src="/images/bigLoader.gif">');
Expand Down Expand Up @@ -87,13 +88,18 @@ function appendProject(json, after){
if (matches) { sound() }
}

html = '<div style="background: ' + (window.first_id >= project.id ? '#cfcfcf' : 'rgb('+r+','+g+','+b+')') + '" class="project ' + ' '+ (matches ? 'match' : '') +'" id="' + project.id + '">' +
'<img src="/images/icons/'+ project.icon +'.gif" alt="" />' +
'<strong>' + project.budjet + '</strong>' +
html =
'<div style="background: ' + (window.first_id >= project.id ? '#cfcfcf' : 'rgb('+r+','+g+','+b+')') + ' url(/images/middle-message.png) repeat-y;" class="project' + (matches ? ' match' : '') +'" id="' + project.id + '">' +
'<div id="projectop"></div>'+
'<div id="projectzag"><img src="/images/icons/'+ project.icon +'.gif" alt="" />' +
'<h3>'+ (project.category != '' ? (project.category +' &raquo; ') : '') + '<a onclick="if($(\'#new_window:checked\').val()){window.open($(this).attr(\'href\'));return false;}else{return true}" href="' + project.url + '">' + project.title + '</a></h3>' +
'</div>' +
'<div id="projectzag_txt">'+
'<p>' + project.desc + '</p>' +
'<a class="up" href="javascript:;" onclick="window.scroll(0,0)">↑</a>' +
'<div class="created_at">' + project.created_at + '</div>' +
'</div>' +
'<div id="projectdata">' + project.created_at + '</div>' +
'<div id="projectcena">' + project.budjet+ '</div>' +
'<div id="projectbottom"></div>'+
'</div>';

if( $('.project').length == 0 ) {
Expand Down
25 changes: 16 additions & 9 deletions public/stylesheets/default.css
@@ -1,22 +1,27 @@
body { font-family: Georgia; font-size: 16px }
/*body { font-family: Georgia; font-size: 16px }
.project { width: 600px; border-top: 1px solid #ddd; padding: 10px 15px 15px 15px }
.project h3 { margin: 0 }
.project strong { float: right }
.project.match { border: 10px solid red }
.project.match { border: 2px solid red }
*/

#nav { text-align: center }
#loader { position: absolute; margin-top: -100px; margin-left: 650px; }
#notifier { position: fixed; top: 10px; right: 45px; width: 220px; }
textarea, select, input { font-family : Georgia; font-size: 20px; padding: 4px; color: #666; }
#feedback { position : fixed; bottom: 0px; right: 20px; background: white; height: 100%; }
/*textarea, select, input { font-family : Georgia; font-size: 20px; padding: 4px; color: #666; }*/
#feedback { position : fixed; bottom: 0px; right: 20px; margin: 10px; background: white; height: 170px; }
#feedback textarea { width: 200px; height: 100px; color: #666 }
#feedback textarea.hover { color: #000; width: 100%; height: 90%; margin: 10px }
#feedback textarea.hover { color: #000; width: 100%; height: 90%; margin-bottom: 10px }
#feedback p { padding: 5px }
#counter { position: fixed; bottom: 10px; right: 10px }
#flashbanner { position: absolute; left: -1000px }
#controls { margin-bottom: 10px }
#stop_words { width: 300px }
#sources { position: fixed; right: 30px; bottom: 0px }
input[type="button"], input[type="submit"] { font-size: 14px }
/*#stop_words { width: 300px }*/
/*#sources { position: fixed; right: 30px; bottom: 0px }*/
/*input[type="button"], input[type="submit"] { font-size: 14px }*/
#twitter { margin: 10px; text-align: right }
a img { border: 0 }
.project img { float: left; margin-right: 5px }
Expand Down Expand Up @@ -44,12 +49,14 @@ a.up { float: right; text-decoration: none }
left: 50%;

margin-left: -300px;
width: 600px;
width: 637px;
height: auto;

background-color: #EEE;
color: #333;
border: 1px solid black;
padding: 12px;
#background: url(/images/middle.png) repeat-y ;
}

.jqmOverlay { background-color: #000; }
Expand Down

0 comments on commit 872cabe

Please sign in to comment.