Daily Archives

Articles indexed Thursday June 10 2010

Page 3/121 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Serialized form fields in Ruby on Rails problem

    - by Violet
    I'm having a problem making serialized columns in my model persist correctly in forms. If my model validation fails I want to redisplay the "new" page with all my model data still in the forms. Right now, everything except the serialized fields seem to persist (if my Order fails to purchase, on the "new" page the email is still filled in but the shipping address fields are not). Is this a Rails bug or am I doing something wrong? My model: class Order < ActiveRecord::Base serialize :shipping_address end My controller: def new @order = Order.new end def create @order = Order.new params[:order] if @order.purchase then render :action => "success" else render :action => "new" end end My view, new.html.haml: = form_for @order do |f| - if @order.errors.any? #errorExplanation %p The following errors occurred: %ul - for msg in @order.errors.full_messages %li= msg %h2 Billing Information = f.label :email = f.text_field :email %h2 Shipping Address = f.fields_for :shipping_address do |b| %p.field.address = b.label :address1 = b.text_field :address1 %p= f.submit "Place Order"

    Read the article

  • Help with database design

    - by Jonny
    Hey im new to database design and having trouble trying to figure this one out. I have two tables Team and Fixtures. Team has rows of football teams and Fixture has 2 of those football teams in each row (home and away team). I want to link team id to home_team and away_team but it doesnt allow me to. Please tell me how i can solve this. Here is an image of my tables/relationships http://i49.tinypic.com/288qwpg.jpg

    Read the article

  • Issue with angular gradient algorithm

    - by user146780
    I have an angular gradient algorithm: GLuint OGLENGINEFUNCTIONS::CreateAngularGradient( std::vector<ARGBCOLORF> &input,POINTFLOAT start, POINTFLOAT end, int width, int height ) { std::vector<GLubyte> pdata(width * height * 4); float pi = 3.1415; float cx; float cy; float r1; float r2; float ang; float px; float py; float t; cx = start.x; cy = start.y; r1 = 0; r2 = 500; ang = end.x / 100; ARGBCOLORF color; for (unsigned int i = 0; i < height; i++) { for (unsigned int j = 0; j < width; j++) { px = j; py = i; if( px * px + py * py <= r2 * r2 && px * px + py * py >= r1 * r1 ) { t= atan2(py-cy,px-cx) + ang; t= t+ pi; if (t > 2* pi) { t=t-2*pi; t=t/(2*pi); } } //end + start color.r = (0 * t) + (120 * (1 - t)); color.g = (50 * t) + (255 * (1 - t)); color.b = (0 * t) + (50 * (1 - t)); color.a = (255 * t) + (200 * (1 - t)); pdata[i * 4 * width + j * 4 + 0] = (GLubyte) color.r; pdata[i * 4 * width + j * 4 + 1] = (GLubyte) color.g; pdata[i * 4 * width + j * 4 + 2] = (GLubyte) 12; pdata[i * 4 * width + j * 4 + 3] = (GLubyte) 255; } } It works fine except the ang variable only controls the end sweep, not the start sweep. The start sweep is always facing the middle left as seen here: http://img810.imageshack.us/img810/9623/uhoh.png Basically I have no control over the end one going this <- way. How could I control this one? Thanks

    Read the article

  • mysqli returns only one row instead of multiple rows

    - by Tristan
    Hello, i'm totally new to mysqli and i took a generated code and adapted it for my need. public function getServeurByName($string) { $stmt = mysqli_prepare($this->connection, "SELECT DISTINCT * FROM $this->tablename where GSP_nom=?"); $this->throwExceptionOnError(); mysqli_stmt_bind_param($stmt, 's', $string); $this->throwExceptionOnError(); mysqli_stmt_execute($stmt); $this->throwExceptionOnError(); mysqli_stmt_bind_result($stmt, $row->idServ, $row->timestamp, ........... ........... $row->email); if(mysqli_stmt_fetch($stmt)) { $row->timestamp = new DateTime($row->timestamp); return $row; } else { return null; } } the problem, this example i took the template on returns only one row instead of all the records. how to fix that please ?

    Read the article

  • Comparing two date / times to find out if 5 mins has lapsed between the two times php

    - by estern
    I need to compare two dates to show an edit link if it is within 5 mins after the post was made, in php. If after 5 mins dont show anything. $answer_post_date = get_the_time("Y-m-d"); $current_date = date("Y-m-d"); $formated_current_date = strtotime($answer_post_date); $formated_answer_post_date = strtotime($current_date); At this point i have two values: 1274414400 ($formated_current_date) 1276056000 ($formated_answer_post_date) I am not sure what to do next to check if the current date/time is ! 5 mins from answer post date. Any suggestions would be great All i really need the answer to be is a Boolean (yes/no) and if yes display the minuets left to show the link to edit.

    Read the article

  • In Django : How to serialize dict object to json ?

    - by Rohit
    I have this very basic problem, >>> serializers.serialize("json", {'a':1}) Traceback (most recent call last): File "<console>", line 1, in <module> File "/usr/lib/pymodules/python2.6/django/core/serializers/__init__.py", line 87, in serialize s.serialize(queryset, **options) File "/usr/lib/pymodules/python2.6/django/core/serializers/base.py", line 40, in serialize for field in obj._meta.local_fields: AttributeError: 'str' object has no attribute '_meta' >>> How can this be done ? Thanks in advance !

    Read the article

  • Is there an existing template for a new C++ Open Source project

    - by esavard
    I want to start a new C++ (Qt) Open Source project and I'm wondering if there is an existing template somewhere for files usually found in an Open Source project but that are not purely source code (README, LICENSE, CHANGELOG, etc.) I could probably find a popular Open Source project for inspiration but if there is some existing generic templates, I will use that instead. Thanks.

    Read the article

  • What's the best self-tracking software for Linux?

    - by trench
    I'm looking for a way to track myself and receive quality data upon which I can write future scripts/programs. For example, I use Google Reader a lot. I'd like to track the hrefs that garner my clicks. Further, I'd like to drop all of the words of each href into a database where they can be stacked in a hierarchical manner. At the end of the week I want to know that "Ubuntu" garnered 448 clicks and "Cheetos" garnered 2. :) That's just one example... I'd like this tracking and data-collecting to extend beyond my browser. I know writing something to do this myself wouldn't be too awfully difficult but if something already exists I'd happily use it. Thanks in advance. Primary OS: Ubuntu 10.04

    Read the article

  • How can you tell the source of the data when using the Stream.BeginRead Method?

    - by xarzu
    When using the Stream.BeginRead Method, and you are reading from a stream into a memory, how is it determined where you are reading the data from? See: http://msdn.microsoft.com/en-us/library/system.io.stream.beginread.aspx In the list of parameters, I do not see one that tells where the data is being read from: Parameters buffer Type: System.Byte[] The buffer to read the data into. offset Type: System.Int32 The byte offset in buffer at which to begin writing data read from the stream. count Type: System.Int32 The maximum number of bytes to read. callback Type: System.AsyncCallback An optional asynchronous callback, to be called when the read is complete. state Type: System.Object A user-provided object that distinguishes this particular asynchronous read request from other requests.

    Read the article

  • Going "behind Hibernate's back" to update foreign key values without an associated entity

    - by Alex Cruise
    Updated: I wound up "solving" the problem by doing the opposite! I now have the entity reference field set as read-only (insertable=false updatable=false), and the foreign key field read-write. This means I need to take special care when saving new entities, but on querying, the entity properties get resolved for me. I have a bidirectional one-to-many association in my domain model, where I'm using JPA annotations and Hibernate as the persistence provider. It's pretty much your bog-standard parent/child configuration, with one difference being that I want to expose the parent's foreign key as a separate property of the child alongside the reference to a parent instance, like so: @Entity public class Child { @Id @GeneratedValue Long id; @Column(name="parent_id", insertable=false, updatable=false) private Long parentId; @ManyToOne(cascade=CascadeType.ALL) @JoinColumn(name="parent_id") private Parent parent; private long timestamp; } @Entity public class Parent { @Id @GeneratedValue Long id; @OrderBy("timestamp") @OneToMany(mappedBy="parent", cascade=CascadeType.ALL, fetch=FetchType.LAZY) private List<Child> children; } This works just fine most of the time, but there are many (legacy) cases when I'd like to put an invalid value in the parent_id column without having to create a bogus Parent first. Unfortunately, Hibernate won't save values assigned to the parentId field due to insertable=false, updatable=false, which it requires when the same column is mapped to multiple properties. Is there any nice way to "go behind Hibernate's back" and sneak values into that field without having to drop down to JDBC or implement an interceptor? Thanks!

    Read the article

  • Essential AIML responses?

    - by user335932
    What do you think are important pattern/temples to program. Like in a chatbot what does EVERY chatbot need a response for? Im just starting out making the aiml file and need some help... Heres the file now. <aiml> <category> <pattern>Hey</pattern> <template>Whats up?</template> <category> <category> <pattern>WHAT ARE YOU?</pattern> <template>I am a chatbot.</template> <category> <category> <pattern>DO YOU LIKE*</pattern> <template>Yes, I love <star/></template> <category> <category> <pattern>WHAT IS*</pattern> <template><star/>? is that what humans call what I did to your mom last night?</template> <category> <category> <pattern>WHEN WERE YOUR BORN*</pattern> <template>I was created in 2010.</template> <category>

    Read the article

  • Can the MVVM-Light ViewModelLocator be used in nested ViewModels?

    - by dthrasher
    The Visual Studio 2008 Designer doesn't seem to like UserControls that reference the MVVM-Light ViewModelLocator. I get an error message like: Could not create an instance of type 'MyUserControl'. For example, the following XAML will cause this behavior if MyUserControl uses the ViewModelLocator to establish its DataContext. <Page x:Class="MyProject.Views.MainView" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:Views="clr-namespace:MyProject.Views" > <Grid> <Views:MyUserControl/> </Grid> </Page> Is the ViewModelLocator only meant to be used in top-level Views?

    Read the article

  • Flex : How to link data to a datagrid ?

    - by Tristan
    Hello, I'm following flex tutorials but i'm not doing exactly as they do, so : What i want I have an input text, with a button 'search'. I want when this button is clicked that the data returned by the function search are displayed in the datagrid. What i have : The text input : <s:TextInput includeIn="DetailServeurs" x="58" y="361" width="209" id="txt_search" text="Default text" focusIn="txt_search_focusInHandler(event)"/> a Search button : <s:Button includeIn="DetailServeurs" x="275" y="361" label="Rechercher" id="btn_rechercher" click="btn_rechercher_clickHandler(event)"/> a clickhandler for this search button : protected function btn_rechercher_clickHandler(event:MouseEvent):void { if(txt_search.text != ""){ getServeurByNameResult.token = serveurService.getServeurByName(txt_search.text); } } and a datagrid : <mx:DataGrid includeIn="DetailServeurs" x="30" y="124" width="1002" height="179" id="dataGrid" dataProvider="{getServeurByNameResult.lastResult}"> <mx:columns> <mx:DataGridColumn headerText="GSP_nom" dataField="GSP_nom"/> <mx:DataGridColumn headerText="port" dataField="port"/> ........ </mx:columns> </mx:DataGrid> So how can i display the results in the datagrid ? Thanks ! ;)

    Read the article

  • Help with Subsonic3 ActiveRecord LINQ query

    - by Saif Khan
    I have the following subsonic entities TInvoiceHeader TAccountAssociation How can I achieve the following in LINQ (subsonic) SELECT * from TInvoiceHeader WHERE custid IN (SELECT custid FROM TAccountAssociation WHERE username = 'a') I need to bind the results to a GridView.

    Read the article

  • CodePlex Daily Summary for Wednesday, June 09, 2010

    CodePlex Daily Summary for Wednesday, June 09, 2010New Projects.NET Transactional File Manager: Transactional File Manager is a .NET API that supports including file system operations such as file copy, move, delete in a transaction. It's an i...3D World Studio Content Pipeline for Windows Phone 7: This is a port of PhotonicGames' project: http://xna3dws.codeplex.com/releases/view/42994 for the Windows Phone 7 tools (XNA 4.0 CTP).Advanced Script Editor for 3D Rad: Advanced Script Editor makes it easier for 3D Rad coders to write scripts. Developed in C#, it features a functions list, a favourites list, object...Ajax ASP.Net Forum: A fast & lightweight open source free forum developed in ASP.Net 3.5, AJAX, CSS, SQL & Javascript Cache (filter-sort-move through table records at ...Axon: Axon is the home automation system that I will be running in my home. It will be a collection of different technologies and projects, often experim...BigBallz: Projeto de site de Bolões para campeonatos diversos. A princípio pensado para copa do mundo de futebol de 2010BigfootMVC: MVC Framework for DotNetNukeBigfootSQL: A StringBuilder for SQL. BigfootSQL was built with simplicity in mind. It assumes that you are comfortable writing SQL but dislike effort required ...Bxf (Basic XAML Framework): Basic Xaml Framework (Bxf) is a simple, streamlined set of UI components designed to demonstrate the minimum framework functionality required to ma...elZerf - elektronische Zeiterfassung: elektronisches Zeiterfassungsystem im Rahmen der Seminararbeit im Modul Web-Anwendungsprogrammierung.IntoFactories.Net - Samples: Project to host samples created by members of the IntoFactories.NET Team blog.Lanchonete: Sistema para controle de lanchonetes. Medieval Dynasties: Medieval Dynasties is a game written in C# 3.5 and XNA 3.1 at the moment. It is inspired by Crusader Kings, Total War and Civilization.PMMsg: A project to replace the standard messaging client on the Windows Mobile platform. Mainly geared towards Windows Mobile 6.5.3 VGA devices. Also an...PunkPong: PunkPong is an open source "Pong" alike game totally written in DHTML (JavaScript, CSS and HTML) that uses keyboard or mouse. This cross-platform a...Renegade Legion Fighter Calculator: In working on assigning fighters to squadrons, flights, and groups for a campaign, I was struck by the sheer amount of calculations I had to make. ...Sharpotify - Spotify .Net Library: Sharpotify is a Spotify library in C#. It is based in Jotify and SharPot projects. It is not a libspotify wrapper, It is a full .Net Spotify protoc...Silverlight load on demand with MEF: With MEF, a Silverlight control can be split in several packages(xap files). Each package can contain one or more pages and it will download on dem...SOLID by example: Source code examples to undestood solid design principles. Most of them were taken from http://www.lostechies.com/SQL Server 2008 Reporting Services RS.EXE Supporting Forms Authentication: A version of RS.EXE that you can use with Forms Authentication in Native Mode. Use the following arguments to specify credentials (just like Basic ...Stripper: Stripper Remove Diacritics and other unwanted caracter to fabric a more standardized file naming.study: studyUncoverPIC: UncoverPIC is a Silverlight Game strongly inspired to the famous Arcade Game "GalsPanic" (see http://en.wikipedia.org/wiki/Gals_Panic ). It was dev...Unity3D Untitled MMO: Unity3D Untitled MMO FrameworkUnnamedShop: UnnamedShopXBStudio.asp.net.automation: A Unit Testing Automation library for asp.netXBStudio.Web: XBStudio Web ApplicationNew Releases3D World Studio Content Pipeline for Windows Phone 7: Initial Release (0.1): This is the first release of the project, with plenty of hackery and kludges to go around, but it mostly works! Let me know if you hit any bugs.Acies: Acies - Alpha Build 0.0.10: Alpha release. Requires Microsoft XNA Framework Redistributable 3.1 (http://www.microsoft.com/downloads/details.aspx?FamilyID=53867a2a-e249-4560-...Advanced Script Editor for 3D Rad: Advanced Script Editor - Version 2.6: Despite various previous releases on the 3D Rad forum, this is the first release on CodePlex.Ajax ASP.Net Forum: First Release: First Release prior to CodePlex Publish (send to admins)So, it doesn't all finish VERSION: 0.1.2 FEATURES Main Home Where all the Forums (called ...Artist Follower for Microsoft Access: Artist Follower 0.5.1: Artists Follower changes: Just one form to manage artists and links!!!Artist Follower for Microsoft Access: Artists Follower 0.5.0: This is the first release of Artist Follower.ASP.NET MVC SiteMap provider - MvcSiteMapProvider: MvcSiteMapProvider 2.0.0 CTP1: This is a community technology preview of MvcSiteMapProvider version 2.0. It is not backwards compatible with older MvcSiteMapProvider versions. ...B&W Port Scanner: Black`n`White Port Scanner 4.0: Version 4 includes: - Improved vulnerability detection tools - Report Creation - Improved Stability - Much better port information database - Nume...BaseCalendar: BaseControls 1.1: BaseControls 1.1 contains the BaseCalendar ASP.NET control. Changes: Rendering TH by default inside THEAD. Added option (ShowMinNumWeeks) to r...BigfootSQL: BigfootSQL Source Code: BigfootSQL C# Version 01Commerce Server 2009 Orders using Pipelines in a Console Application: ConsoleApplication To PLace Orders: ConsoleApplication To PLace Orders with Commerce Server 2009 foundationCommunity Forums NNTP bridge: Community Forums NNTP Bridge V33: Release of the Community Forums NNTP Bridge to access the social and anwsers MS forums with a single, open source NNTP bridge. This release has ad...Community Forums NNTP bridge: Community Forums NNTP Bridge V34: Release of the Community Forums NNTP Bridge to access the social and anwsers MS forums with a single, open source NNTP bridge. This release has ad...ContainerOne - C# application server: V0.1.2.0: New minor release containing: Integration test component for runtime testing Refactored and cleaned solution files First unit testsExtend SmallBasic: Teaching Extensions v.020: Moved Tortoise.approve to ProgramWindow.TakeScreenShot()fleet It: v0.06 Alpha: v0.06 Alpha - Features Caching implemented for fleets Various Bug fixes Implemented Settings. Resolved logical issue with Getting fleets U...Frotz.NET: Frotz.NET B2: In addition to B1 changes: - Added ZTools to enable debugging view of zcode files - Added rudimentary scroll back buffer. B1 Changes: - Got Adapt...FsObserver: FsObserver 2.0: This is basically the same as FsObserver 1.0 but the "-help" documentation has been cleaned up somewhat and the code has been refactored so that it...GPdotNET - Genetic Programming Tool: GPdotNETv1.0: GPdotNET v.1.0 - more details on http.bhrnjica.wordpress.com/gpdotnetHERB.IQ: Alpha 0.1 Source code release 8: Alpha 0.1 Source code release 8imdb movie downloader: myImdb 0.9.3: myImdb 0.9.3imdb movie downloader: myImdb 0.9.4: myImdb 0.9.4jccc .NET smart framework: jccc .NET smart framework version 1.2010.06.07: jccc .NET smart framework version 1.2010.06.07 added oracle databases supportLongBar: LongBar 2.1 Build 313: - Fixed library and updates to work with updated live services - Options: You can disable shadow nowMDownloader: MDownloader-0.15.17.59623: Fixed FileFactory provider. Improvied postpone policies. Added network request limiter.MediaCoder.NET: MediaCoder.NET v1.0 beta 1.1: Installer for MediaCoder.NET v1.0 beta1.1. It can now convert files with spaces in the path or filename. I have also created filter for the SaveFil...MediaCoder.NET: MediaCoder.NET v1.0 beta 1.1 Source Code: Source Code for MediaCoder.NET v1.0 beta 1.1.mesoBoard: mesoBoard - 0.9.1 beta: Fixed file download permissions Released under the New BSD License.MPCLI: Alpha Release (0.1.0.0): This release has core functionality and is considered a potential candidate for a feature complete release of this library. However, suggestions fo...N2 CMS: 2.0: N2 is a lightweight CMS framework for ASP.NET. It helps professional developers build great web sites that anyone can update. Major Changes (1.5 -...NHTrace: NHTrace-47571: NHTrace-47571NodeXL: Network Overview, Discovery and Exploration for Excel: NodeXL Class Libraries, version 1.0.1.125: The NodeXL class libraries can be used to display network graphs in .NET applications. To include a NodeXL network graph in a WPF desktop or Windo...NSoup: NSoup 0.2: NSoup 0.2 corresponds to jsoup version 1.1.1. List of changes can be viewed here.Opalis Community Releases: Integration Pack for Data Manipulation: The Integration Pack for Data Manipulation enables you to perform a wider variety of data manipulation tasks as well as aggregate data into common ...Performance Analysis of Logs (PAL) Tool: PAL v2.0 Beta 1: Fixed Counter Sorting: Fixed a minor bug where duplicate counter expression paths were not being removed. Analysis Added: Added LogicalDisk Read/...RoTwee: RoTwee (12.0.0.0): Trial version. 17925 Make it possible to change window sizeSharpotify - Spotify .Net Library: Sharpotify.Library 1.0: Sharpotify Library: Stable release. You can connect with spotify, search, browse (tracks, albums, artists), get a music stream, create and edit you...Silverlight load on demand with MEF: mal.Web.Silverlight.MEF 1.0.0.0: mal.Web.Silverlight.MEF 1.0.0.0sMAPtool: sMAPtool v0.7e (without Maps): + Added: color value expansion bar for hmap (right click to select color scheme) + Added: more complex hmap editing, uses now 4 point bounding rect...SQL Server 2008 Reporting Services RS.EXE Supporting Forms Authentication: Initial release: Enjoy!Stripper: Stripper 0.1.1 (CLi): Stripper Remove Diacritics and other unwanted caracters to fabric a more standardized file naming. Especially French caracter and maybe other lang...Unity3D Untitled MMO: v1: versionUrzaGatherer: UrzaGatherer 2.01a: New version with some minors bugs corrected.VCC: Latest build, v2.1.30608.0: Automatic drop of latest buildVCC: Latest build, v2.1.30608.1: Automatic drop of latest buildWatermarker.NET: 0.1.3811: A newer version with some improvements. I release this as a .zip archive, because settings are added here, so there will be .exe and .config files.Yet Another GPS: Alfa Release: Alfa working releaseMost Popular ProjectsDozer Enterprise Library for .NETEmployee Management SystemWiiMote PhysicsVisualStudio 2010 JavaScript OutliningSpider CompilerConcurrent CacheOil Slick Live FeedsCSUFVGDC Summer JamWinGetSiteMap Utility for DNN Blog ModuleMost Active ProjectsCommunity Forums NNTP bridgepatterns & practices – Enterprise LibraryRhyduino - Arduino and Managed CodejQuery Library for SharePoint Web ServicesRawrNB_Store - Free DotNetNuke Ecommerce Catalog ModuleAndrew's XNA HelpersBlogEngine.NETStyleCopCustomer Portal Accelerator for Microsoft Dynamics CRM

    Read the article

  • Purpose of lua_lock and lua_unlock?

    - by anon
    What is the point of lua_lock and lua_unlock? The following implies it's important: LUA_API void lua_gettable (lua_State *L, int idx) { StkId t; lua_lock(L); t = index2adr(L, idx); api_checkvalidindex(L, t); luaV_gettable(L, t, L->top - 1, L->top - 1); lua_unlock(L); } LUA_API void lua_getfield (lua_State *L, int idx, const char *k) { StkId t; TValue key; lua_lock(L); t = index2adr(L, idx); api_checkvalidindex(L, t); setsvalue(L, &key, luaS_new(L, k)); luaV_gettable(L, t, &key, L->top); api_incr_top(L); lua_unlock(L); } The following implies it does nothing: #define lua_lock(L) ((void) 0) #define lua_unlock(L) ((void) 0) Please enlighten.

    Read the article

  • Active Record Validations : uniqueness of

    - by Elliot
    Hey guys, I'm using http://ar.rubyonrails.org/classes/ActiveRecord/Validations/ClassMethods.html#M000086 to validate records. My form is currently a remote form, using RJS. My question, is how to I return the :message (for errors) to the page through ajax (and I assume the create.rjs file)? Best, Elliot

    Read the article

  • Java (or possibly other languages) learning path

    - by bgo
    I am familiar (as a self-learner) with C, python and php such that i can solve some problems involving simple steps (for example, i easily do calculations for physics lab reports with python which normally would take 4x-5x times longer with a calculator). The point here is, as doing such things, i learnt the idea / concepts of programming language and problem solving along with oop or fuctional programming etc. Recently i have started Java and, with the familiarity of other languages, i am doing well for starters but i need guidence. -I am thinking of learning syntax from sun java tutorials and then practicing with codingbat.com or similar sites. I need a reference book that i can study deeper aspects of the topics i am learning. What do you suggest about these? -The problem is (and always have been) the lack of practice. I need coding and problem-solving practices sources. I stuck at the point where i can't figure out what to do next. Can you suggest any source (possibly like codingbat)? If i could plan a learning trail, i can progress faster and efficiently. So i need ideas, comments, suggestions. Thanks in advance.

    Read the article

  • Install "Massive Coupon"

    - by ffffff
    I'want to install "Massive Coupon" http://github.com/robstyles/Massive-Coupon---Open-source-groupon-clone I've set up apache2 + mod_wsgi + mysql on Ubuntu 9 And written the following settings.py # Django settings for massivecoupon project. import socket, os . . DATABASE_ENGINE = 'mysql' # 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'. DATABASE_NAME = 'grouponpy' # Or path to database file if using sqlite3. DATABASE_USER = 'grouponpy' # Not used with sqlite3. DATABASE_PASSWORD = 'password' # Not used with sqlite3. DATABASE_HOST = 'localhost' # Set to empty string for localhost. Not used with sqlite3. DATABASE_PORT = '' # Set to empty string for default. Not used with sqlite3. What I have to do additional then?

    Read the article

  • A[i] * A[j] = k in O(nlog(n))

    - by gleb-pendler
    A is an Array of n positive int numbers k given int Algorithm should find if there is a pair of numbers which product gives the result a. A[i] * A[j] = k b. A[i] = A[j] + k if there is such a couple the algorithm should return thier index. thanks in advance.

    Read the article

  • Blend 4 breaks VS2010 for Silverlight

    - by Adrian
    Hi, I had VS2010 running fine with Silverlight development. Then I installed Expression Blend 4. Now when I run VS2010 and try to debug a silverlight app I get an error saying "Unable to start debugging. The silverlight developer runtime is not installed. Please install a matching version." I've tried uninstalling silverlight tools, and reinstalling them from scratch (the latest april version). But I still get the same message. So basically I'm now unable to do VS2010 SL development. I'm on the verge of just rolling back to my last system restore point and giving up on Blend. But if I do that I'd be worried that Product Activation would never allow me to reinstall it in the future, since the MSDN download page implies I'm only ever allowed to install it on a single machine. Any help appreciated. Thanks

    Read the article

  • Why is my Repeater null in code behind?

    - by Rob Stevenson-Leggett
    I'm just starting a new project and I am getting some really weird stuff happening. ASP.NET 3.5, VS2008. I've tried rebuild, close VS, delete everything and get from svn again but I cannot understand why the repeater in the following is null on page_load. I know this is going to be a headslapping moment. Help me out? Markup: <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="GalleryControl.ascx.cs" Inherits="Site.UserControls.GalleryControl" %> <asp:Repeater ID="rptGalleries" runat="server"> <HeaderTemplate><ul></HeaderTemplate> <ItemTemplate> <li>wqe</li> </ItemTemplate> <FooterTemplate></ul></FooterTemplate> </asp:Repeater> Code behind public partial class GalleryControl : System.Web.UI.UserControl { protected void Page_Load(object sender, EventArgs e) { rptGalleries.DataSource = new[] {1, 2, 3, 4, 5}; rptGalleries.DataBind(); } } Why is my repeater null? What the F is going on?

    Read the article

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