Daily Archives

Articles indexed Saturday May 15 2010

Page 7/78 | < Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >

  • IEEE 1394 Firewire Card is not visible in Device Manager in WIndows 7

    - by Shyam
    I have a IEEE 1394 card that I have placed in one of the PCI slots of my Windows 7 PC. I have moved to Windows just last week and Windows is not detecting this card. It is not listed in the Devide Manager. Earlier when I used Fedora 12, I was able to use this interface for capturing videos from my DV Camera. The manufacturer is Tech-Com, which has not provided a driver CD for this. What can I possibly try?

    Read the article

  • How to target Safari for Mac only?

    - by Moak
    Hi I've cross browser fixed a site on all thinkable PC browsers, including Safari. Now my smart ass designer sent me a screen shot of the whole layout collapsing on mac. I have an idea how to solve it (reduce the margin on an element by a few pix), but i don't know how to target Safari only, preferably Safari mac only. What's the best way to do this?

    Read the article

  • WordPress 'comment is awaiting moderation.' message not appearing when a comment is submitted?

    - by cs
    Everything is pretty standard from WP samples, with minor modifications. But when a comment is submitted, it does not show the "your comment is awaiting moderation" message. The comments.php: <div id="comment-block"> <h4><?php comments_number('No Responses', 'One Response', '% Responses' );?> to &#8220;<?php the_title(); ?>&#8221;</h4> <ul id="commentlist"> <?php wp_list_comments('type=comment&callback=mytheme_comment'); ?> </ul> <?php // this is displayed if there are no comments so far ?> <?php if ('open' == $post->comment_status) : ?> <!-- If comments are open, but there are no comments. --> <?php else : // comments are closed ?> <!-- If comments are closed. --> <p class="nocomments">Comments are closed.</p> <?php endif; ?> <?php if ('open' == $post->comment_status) : ?> <h4>Leave a reply</h4> <div class="cancel-comment-reply"> <small><?php cancel_comment_reply_link(); ?></small> </div> <?php if ( get_option('comment_registration') && !$user_ID ) : ?> <p>You must be <a href="<?php echo get_option('siteurl'); ?>/wp-login.php?redirect_to=<?php echo urlencode(get_permalink()); ?>">logged in</a> to post a comment.</p> <?php else : ?> <form action="<?php echo get_option('siteurl'); ?>/wp-comments-post.php" method="post" id="commentform"> <?php if ( $user_ID ) : ?> <p class="loggedIn">Logged in as <a href="<?php echo get_option('siteurl'); ?>/wp-admin/profile.php"><?php echo $user_identity; ?></a>. <a href="<?php echo wp_logout_url(get_permalink()); ?>" title="Log out of this account">Log out &raquo;</a></p> <?php else : ?> <table width="675" cellpadding="0" cellspacing="0" border="0"> <tr><td style="padding-right: 20px;"><label for="author">Name <?php if ($req) echo "(required)"; ?></label></td> <td style="padding-right: 20px;"><label for="email">Email <?php if ($req) echo "(required)"; ?></label> <small>(will not be published)</small></td> <td><label for="url">Website <?php if ($req) echo "(required)"; ?></label></td> </tr> <tr><td style="padding-right: 20px;"><input type="text" name="author" id="author" value="<?php echo $comment_author; ?>" class="text" tabindex="1" <?php if ($req) echo "aria-required='true'"; ?> /></td> <td style="padding-right: 20px;"><input type="text" name="email" id="email" value="<?php echo $comment_author_email; ?>" class="text" tabindex="2" <?php if ($req) echo "aria-required='true'"; ?> /></td> <td><input type="text" name="url" id="url" value="<?php echo $comment_author_url; ?>" class="text" tabindex="3" /></td> </tr> </table> <?php endif; ?> <label for="comment">Comment <?php if ($req) echo "(required)"; ?></label><br /> <textarea name="comment" id="comment" rows="10" tabindex="4" class="text"></textarea> <input name="submit" type="image" src="<?php bloginfo('template_directory'); ?>/images/submit_button.png" width="130" height="24" alt="Submit" id="submit" tabindex="5" /> <?php comment_id_fields(); ?> <?php do_action('comment_form', $post->ID); ?> </form> <div class="clear"></div> <?php endif; // If registration required and not logged in ?> </div> <?php endif; // if you delete this the sky will fall on your head ?> And the mytheme_comments function in functions.php function mytheme_comment($comment, $args, $depth) { $GLOBALS['comment'] = $comment; ?> <li <?php comment_class(); ?> id="li-comment-<?php comment_ID() ?>"> <div id="comment-<?php comment_ID(); ?>"> <span class="comment-author vcard"> <?php printf(__('<cite class="fn">%s</cite> <span class="says">says at</span>'), get_comment_author_link()) ?> </span> <?php if ($comment->comment_approved == '0') : ?> <em><?php _e('Your comment is awaiting moderation.') ?></em> <br /> <?php endif; ?> <span class="comment-meta commentmetadata"><a href="<?php echo htmlspecialchars( get_comment_link( $comment->comment_ID ) ) ?>"> <?php printf(__('%2$s, %1$s'), get_comment_date(), get_comment_time()) ?></a><?php edit_comment_link(__('(Edit)'),' ','') ?></span> <?php comment_text() ?> <div class="reply"> <?php comment_reply_link(array_merge( $args, array('depth' => $depth, 'max_depth' => $args['max_depth']))) ?> </div> </div> <?php } ?>

    Read the article

  • Problems setting up AuthLogic

    - by sscirrus
    Hi all, I'm trying to set up a simple login using AuthLogic into my User table. Every time I try, the login fails and I don't know why. I'm sure this is a simple error but I've been hitting a brick wall with it for a while. #user_sessions_controller def create @user_session = UserSession.new(params[:user_session]) if @user_session.save flash[:notice] = "Login successful!" else flash[:notice] = "We couldn't log you in. Please try again!" redirect_to :controller => "index", :action => "index" end end #_user_login.html.erb (this is the partial from my index page where Users log in) <% form_tag user_session_path do %> <p><label for="login">Login:</label> <%= text_field_tag "login", nil, :class => "inputBox", :id => "login", </p> <p><label for="password">Password: </label> <%= password_field_tag "password", nil, :class => "inputBox", :id => "password", </p> <p><%= submit_tag "submit", :class => "submit" %></p> <% end %> I had Faker generate some data for my user table but I cannot log in! Every time I try it just redirects to index. Where am I going wrong? Thanks everybody.

    Read the article

  • Import text file crunching library for Java/Groovy ?

    - by devdude
    In a lot of real life implementations of applications we face the requirement to import some kind of (text) files. Usually we would implement some (hardcoded?) logic to validate the file (eg. proper header, proper number of delimiters, proper date/time value,etc.). Eventually also need to check for the existence of related data in a table (eg. value of field 1 in text file must have an entry in some basic data table). While XML solves this (to some extend) with XSD and DTD, we end up hacking this again and again for proprietary text file formats. Is there any library or framework that allows the creation of templates similar to the xsd approach ? This would make it way more flexible to react on file format changes or implement new formats. Thanks for any hints Sven

    Read the article

  • How to functionally generate a tree breadth-first. (With Haskell)

    - by Dennetik
    Say I have the following Haskell tree type, where "State" is a simple wrapper: data Tree a = Branch (State a) [Tree a] | Leaf (State a) deriving (Eq, Show) I also have a function "expand :: Tree a - Tree a" which takes a leaf node, and expands it into a branch, or takes a branch and returns it unaltered. This tree type represents an N-ary search-tree. Searching depth-first is a waste, as the search-space is obviously infinite, as I can easily keep on expanding the search-space with the use of expand on all the tree's leaf nodes, and the chances of accidentally missing the goal-state is huge... thus the only solution is a breadth-first search, implemented pretty decent over here, which will find the solution if it's there. What I want to generate, though, is the tree traversed up to finding the solution. This is a problem because I only know how to do this depth-first, which could be done by simply called the "expand" function again and again upon the first child node... until a goal-state is found. (This would really not generate anything other then a really uncomfortable list.) Could anyone give me any hints on how to do this (or an entire algorithm), or a verdict on whether or not it's possible with a decent complexity? (Or any sources on this, because I found rather few.)

    Read the article

  • AJAX, Subdomains and the 200 OK response.

    - by b. e. hollenbeck
    A non-hypothetical but abstracted situation: I have a domain www.foo.com, from which I'm making an AJAX POST to beta.foo.com. Examining the XHR object, I see a response header of 200 OK, but no response text - I even get a response 12B long, which is the exact response (a 12-character string) that I'm expecting - but the response text is blank. If this is a cross-domain issue, why am I getting 200 OK, and better yet - why am I seeing the PHP functions fire on the beta.foo.com side - yet getting no response?

    Read the article

  • beginning oop php question: do constructors take the place of getter?

    - by Joel
    I'm working through this tutorial: http://www.killerphp.com/tutorials/object-oriented-php/php-objects-page-3.php At first he has you create a setter and getter method in the class: <?php class person{ var $name; function set_name($new_name){ $this->name=$new_name; } function get_name(){ return $this->name; } } php?> And then you create the object and echo the results: <?php $stefan = new person(); $jimmy = new person(); $stefan ->set_name("Stefan Mischook"); $jimmy ->set_name("Nick Waddles"); echo "The first Object name is: ".$stefan->get_name(); echo "The second Object name is: ".$jimmy->get_name(); ?> Works as expected, and I understand. Then he introduces constructors: class person{ var $name; function __construct($persons_name) { $this->name = $persons_name; } function set_name($new_name){ $this->name=$new_name; } function get_name(){ return $this->name; } } And returns like so: <?php $joel = new person("Joel"); echo "The third Object name is: ".$joel->get_name(); ?> This is all fine and makes sense. Then I tried to combine the two and got an error, so I'm curious-is a constructor always taking the place of a "get" function? If you have a constructor, do you always need to include an argument when creating an object? Gives errors: <?php $stefan = new person(); $jimmy = new person(); $joel = new person("Joel Laviolette"); $stefan ->set_name("Stefan Mischook"); $jimmy ->set_name("Nick Waddles"); echo "The first Object name is: ".$stefan->get_name(); echo "The second Object name is: ".$jimmy->get_name(); echo "The third Object name is: ".$joel->get_name(); ?>

    Read the article

  • Adventures in MVVM &ndash; My ViewModel Base &ndash; Silverlight Support!

    - by Brian Genisio's House Of Bilz
    More Adventures in MVVM In my last post, I outlined the powerful features that are available in the ViewModelSupport.  It takes advantage of the dynamic features of C# 4.0 (as well as some 3.0 goodies) to help eliminate the plumbing that often comes with writing ViewModels.  If you are interested in learning about the capabilities, please take a look at that post and look at the code on CodePlex.  When I wrote about the ViewModel base class, I complained that the features did not work in Silverlight because as of 4.0, it does not support binding to dynamic properties.  Although I still think this is a bummer, I am happy to say that I have come up with a workaround.  In the Silverlight version of my base class, I include a PropertyCollectionConverter that lets you bind to dynamic properties in the ViewModelBase, especially the convention-based commands that the base class supports. To take advantage of any properties that are not statically defined, you can bind to the Properties property of the ViewModel and pass in a converter parameter for the name of the property you want to bind. For example, a ViewModel that looks like this: public class ExampleViewModel : ViewModelBase { public void Execute_MyCommand() { Set("Text", "Foo"); } } Can bind to the dynamic property and the convention-based command with the following XAML. <TextBlock Text="{Binding Properties, Converter={StaticResource PropertiesConverter}, ConverterParameter=Text}" Margin="5" /> <Button Content="Execute MyCommand" Command="{Binding Properties, Converter={StaticResource PropertiesConverter}, ConverterParameter=MyCommand}" Margin="5" /> Of course, it is not as pretty as binding to Text and MyCommand like you can in WPF.  But, it is better than having a failed feature.  This allows you to share your ViewModels between WPF and Silverlight very easily.  <BeatDeadHorse>Hopefully, in Silverlight 5.0, we will see binding to dynamic properties more directly????</BeatDeadHorse>

    Read the article

  • Complete Link Building Strategies

    Link building is essential for ranking the site on the search engine. The page ranking on the search engine is influenced by the number of backlinks to the site. The higher the amount of backlinks pointing to the site, the higher chances it will rank on the search engine. There are plenty of ways to build the backlinks of a website.

    Read the article

  • Jquery Close/Open Multiple Toggles

    - by Pedro
    Hi, I have the toggle in my menu Working successfully for the two links that I have within it. Because the top link once toggled covers the other link, there is no problem. But since the link beneath it leaves the top link exposed, a user could click that and now have two toggled items open and pretty much stacked on top of each other. Is there a way for me to check if the other toggled item is open and if so, close it? Thanks! <div class="parents-toggle"> <a href="#" id="customize-toggle">Customize</a><br/> <div class="menu-toggle hidden" id="customize-menu"> <div class="menu-toggle-one"> <h3>Background</h3> <ul> <li><a href="#">Dark Wood</a></li> <li><a href="#">Wallpaper</a></li> <li><a href="#">Bricks</a></li> <li><a href="#">Planks</a></li> <li><a href="#">Default</a></li> </ul> </div> <div class="menu-toggle-two"> <h3>Layout</h3> <ul> <li><a href="#">Grid</a></li> <li><a href="#">List</a></li> <li><a href="#">Full</a></li> </ul> </div> </div> </div> <a href="/submit/">Submit video</a><br/> <div class="parents-toggle"> <a href="#" id="channels-toggle">Channels</a> <div class="menu-toggle hidden" id="channels-menu"> <div class="menu-toggle-one"> <ul> <li><a href="#">Automotive</a></li> <li><a href="#">Comedy</a></li> <li><a href="#">Movies</a></li> <li><a href="#">Weather</a></li> </ul> </div> <div class="menu-toggle-two"> <ul> <li><a href="#">Business</a></li> <li><a href="#">Commercials</a></li> <li><a href="#">Music</a></li> <li><a href="#">Technology</a></li> </ul> </div> </div> </div> </div> <script> $("#customize-toggle").click(function () { $("#customize-menu").toggle(); }); $("#channels-toggle").click(function () { $("#channels-menu").toggle(); }); </script>

    Read the article

  • What, if any, is wrong with this definition of letrec in Scheme?

    - by Lajla
    R5RS gives proposed macro definitions for library forms of syntax: http://schemers.org/Documents/Standards/R5RS/HTML/r5rs-Z-H-10.html#%_sec_7.3 Which also defines letrec, in a very complicated way, certainly not how I would define it, I would simply use: (define-syntax letrec2 (syntax-rules () ((letrec2 ((name val) ...) body bodies ...) ((lambda () (define name val) ... body bodies ...))))) As far as I understand the semantics of letrec, which I use very often as a named let. It works in this way, however as I've had my fair share of debates with philosophers who think they can just disprove special relativity or established phonological theories, I know that when you think you have a simple solution to a complex problem, it's probably WRONG. There has got to be some point where this macro does not satify the semantics of letrec else they'd probably have used it. In this definition, the definitions are local to the body of the letrec, they can refer to each other for mutual recursion, I'm not quite sure what (if any) is wrong.

    Read the article

  • Productivity features in VS, how to display documentation

    - by drasto
    I used to program quite a lot in Java, recently I've began to work with C#. I think that most of advantages of C# (comparing to Java) are corrupted by VS. Now what really makes me crazy is intelisence. It offers only list of classes of that are already in "using". I would like to see suggestions of all classes from all libraries. Then, when I finally remember the name of class I want to use and type it manually I have to confirm "using"(by clicking pop-up(!)). This is cost me some time and makes me nervous. Most important of all then I'm choosing between methods or classes, filling parameters of methods etc. I need to see documentation of those classes, methods etc. VS displays just a small tool tip that is contains only summary what is completely unsatisfactory. It does not even contain methods return type(!) and parameters. Resharper does not solve any of these. Its suggestions are also mostly useless(it suggest actions I don't want to do). As well I'd like to see Resharper's sugestion not only when I'm on the line in task. Can somebody suggest a solution ? Maybe some addon, how to change it in settings or alike? Other productivity features or a way how to "generally" set shortcuts to be the same as in Java would be also appreciated.

    Read the article

  • Emacs comment-region in C mode

    - by Kinopiko
    In GNU Emacs, is there a good way to change the comment-region command in C mode from /* This is a comment which extends */ /* over more than one line in C. */ to /* This is a comment which extends over more than one line in C. */ ? I have tried (setq comment-multi-line t) but this does not help. There is a section on multi-line comments in the Emacs manual, but it does not mention anything.

    Read the article

  • How to center text around point using xaml

    - by Pete d'Oronzio
    I would like to be able to place the word "hello" centered on a specific point. I need to do this completely in XAML without extra code. Best I can tell, all the text alignment properties/styles in XAML act on text within some bouding canvas or other element. Since I don't know the length of the text I want to center, I can't center it using my own code. The reason I need to solve the problem entirely in XAML is that I'm not using WPF to create the XAML, I'm writing it directly to an XML DOM. It will then be loaded into a Silverlight or WPF control for display. In most graphic languages, including SVG, which is where my code originated, text can be aligned against a "stationary point" without a bounding box. Any suggestions appreciated

    Read the article

< Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >