Controller action:
public string Index(){
var tmp = (from i in Message.message
where i.To == "bognjen" && i.Read == false
select i.Read).Count().ToString();
return tmp;
}
Part of View:
<li><a>Inbox <%=Html.Action("Index","MyController")%></a></li>
When action Index return string it is not...
Hey guys, I have a search field that is not submitting when the enter key is hit, this issue is only happening on IE8, every other browser is working just fine (even IE6). Please guys I need a hand with his, find below the code I have for it.
<div class="box-search">
<input type="text" class="text-box" id="text-search" /...
Hello,
For some reason my Submit and Cancel buttons are not being wrapped in the form tag like I expect them to be (based on their position with in the form tag in the HTML) when I have their float property set to right and left respectively. The two buttons are positioned just outside & below the form div to the far right & left sides....
Here is the ASP.Net MVC2 code that I use to display a textbox input.
<div id="blackbar">
<p>Sistema de Evaluaciones de Docentes</p>
<%: Html.TextBox("termino","") %>
<img src="../../Content/search.png" alt="search" />
</div>
Here is how it renders:
<div id="blackbar">
<p>Sistema de Evaluaciones de Docentes</p>
<in...
I have a two column layout, using a container and a div called "left" and a div called "Right". How do I make sure that the div#right is only 500px, but div#left is as big as the user's browser will allow ...?
Here's what I have now:
<div id="container">
<div id="left" style="float:left"> </div>
<div id="right" style="float: right;...
Hi! I'm having a problem with overflow and width in Google Chrome/Webkit. This is a follow-up question on this question, there you will find the CSS. I need to have visibility: hidden to fix the problem in the first question.
The problem is visible in the screenshots below.
Why does this attribute affect the width in Webkit? Can I solv...
Have been using a simple CSS only tooltip.
Working Example
css:
.tip
{
position:relative;
}
.tip span.tooltip
{
display:none;
background:#ff5112;
border:1px solid #9C0;
}
.tip:hover span.tooltip
{
display:block;
position:absolute;
top:2em; left:2em; width:15em;
border:1px solid #0cf;
background-colo...
On the mobile site I'm building, I need the top header to stay fixed positioned.
I am aware of the fixed position solution for Mobile Safari as seen here:
http://doctyper.com/archives/200808/fixed-positioning-on-mobile-safari/
I tried it and it works well. However, I was wondering if there's a single solution that works for all major...
in jquery/javascript I'm trying to find how far left an element is with position:relative. There are several elements between this one and the left of the screen. since it is positioned:relative and float:left using:
$(this).css('left');
gives me '0px' every time. So how do I found how far the element is from the left of the scre...
I'm looking to have an image object that looks like it's "pinned" to the side of my fixed-width page. but it seems to be contradictory - in order to style it, the div with the image has to be in a separate div than the main content, but in order for it to work in the layout, the div with the image can't be a separate div from the main co...
:-moz-system-metric(touch-enabled) looks like a really useful CSS selector for working on mobile sites.
Unfortunately Webkit is dominant on mobile touch devices so does anyone know if there is a Webkit equivalent?
(Ideally it'd be good if this was managed by CSS3 media queries)
Edit: Looks like it is supported in Gecko as a media que...
** Edit 3:**
Another example of what I try to achive:
+--------------------+
| |
| +--++--++--++--+ |
| |1 ||2 ||3 ||4 | |
| | || |+--+| | |
| +--+| |+--+| | |
| +--+| ||7 |+--+ |
| |5 |+--+| |+--+ |
| | |+--+| ||8 | |
| | ||6 || |+--+ |
| +--+| |+--+ |
| +--+ |
| ...
Hi Everyone,
I've been trying to figure out a new creative way to show confirmation a message has been sent. My idea is to actually TWIRL, FLIP or ROTATE the postcard using CSS3 Animation so the frontside appears after the person clicks on submit. Here is my link:
link text
I don't want to use flash anymore!!
Anyone can point me in ...
Edit: I figured this out. jQuery Cycle plugin adds a z-index to every item it works through, thus the first item always had the highest z-index, messing up all the links. Removing the z-index functionality from the plugin has fixed it.
Hi there,
I'm currently building a cycling div using jQuery cycle that has a few inside links. Basica...
I have some <td> elements with dotted 1px borders on the bottom. Each element is fixed width. This means that sometimes the borders end up like this, with abutting dots that make a dark spot in the border:
-- -- -- --|-- -- -- --
but other times they render correctly, like this:
-- -- -- --| -- -- --
I can move them around by chang...
I have a box where I am trying to add a button to the bottom right corner, yet when I try to float it right, it ends up outside of the div that I have placed it in. How can I fix this?
Link To Live Example
Code:
<!doctype html>
<html>
<head>
<style>
#sidebar {
width: 340px;
float:left;
...
If I have a HTML element <header> and apply some margins to this HTML5 element through CSS as:
header{
margin:10px 0;
}
The <header> element is not spaced 10 px from rest of the elements. But if I modify my CSS rule like below:
header{
margin:10px 0;
display:block;
}
then the <header> element is spaced accordingly.
So, my q...
i was wondering how can i add images to links with css that is compatible across FF, IE and Opera browsers?
...
<div class="build-editor" id="section-content">
<link href="/stylesheets/upload-from-disk.css?1280508898" media="screen" rel="stylesheet" type="text/css">
<div class="attachments">
<h1 class="at-header">Attachments</h1>
<div class="at-options">
.
.
.
In ie8 and 7, this stylesheet is never loaded... why?
...
Hello,
I am trying to make a sort of progress bar that gets filled, with text inside that is on the left, in the center, and SOMETIMES on the right.
I got it (almost) working, my only issue so far is that sometimes the text in the middle gets too long, and so it gets spanned out of the div. Meaning it wraps around, and takes sort of 2 ...