Search Results

Search found 20484 results on 820 pages for 'small projects'.

Page 139/820 | < Previous Page | 135 136 137 138 139 140 141 142 143 144 145 146  | Next Page >

  • Looking to reimplement build toolchain from bash/grep/sed/awk/(auto)make/configure to something more

    - by wash
    I currently maintain a few boxes that house a loosely related cornucopia of coding projects, databases and repositories (ranging from a homebrew *nix distro to my class notes), maintained by myself and a few equally pasty-skinned nerdy friends (all of said cornucopia is stored in SVN). The vast majority of our code is in C/C++/assembly (a few utilities are in python/perl/php, we're not big java fans), compiled in gcc. Our build toolchain typically consists of a hodgepodge of make, bash, grep, sed and awk. Recent discovery of a Makefile nearly as long as the program it builds (as well as everyone's general anxiety with my cryptic sed and awking) has motivated me to seek a less painful build system. Currently, the strongest candidate I've come across is Boost Build/Bjam as a replacement for GNU make and python as a replacement for our build-related bash scripts. Are there any other C/C++/asm build systems out there worth looking into? I've browsed through a number of make alternatives, but I haven't found any that are developed by names I know aside from Boost's. (I should note that an ability to easily extract information from svn commandline tools such as svnversion is important, as well as enough flexibility to configure for builds of asm projects as easily as c/c++ projects)

    Read the article

  • Should the code being tested compile to a DLL or an executable file?

    - by uriDium
    I have a solution with two projects. One for project for the production code and another project for the unit tests. I did this as per the suggestions I got here from SO. I noticed that in the Debug Folder that it includes the production code in executable form. I used NUnit to run the tests after removing the executable and they all fail trying to find the executable. So it definitely is trying to find it. I then did a quick read to find out which is better, a DLL or an executable. It seems that an DLL is much faster as they share memory space where communication between executables is slower. Unforunately our production code needs to be an exectuable. So the unit tests will be slightly slower. I am not too worried about that. But the project does rely on code written in another library which is also in executable format at the moment. Should the projects that expose some sort of SDK rather be compiled to an DLL and then the projects that use the SDK be compiled to executable?

    Read the article

  • Open source real life license examples: yours or others

    - by donpal
    I'm aware of the usual list of open source licenses, so I'm not even going to list it here. What I'd like to ask is about your open source projects (whether out or planned for the future), and why you're planning to choose a certain license over the other. Basically say I went for X license because I wanted Y and that other license didn't provide it for me. I understand that the language itself can make a difference in the choice of license: interpreted languages like PHP vs. compiled languages like Java. I'm mostly interested in hearing about PHP projects, but of course additional insights are welcome. You may even have chosen that particular language for a licensing reason. Ideally I want to hear answers from people who were involved in the actual project (i.e. your own project), because that usually means you've put some thought into the license yourself and understand the implications of that license. But examples of existing projects that aren't your own are OK. Please just say why you think that license was good/bad for them. But first-hand experience is preferred. Looking forward to hearing some informative input.

    Read the article

  • Entity Framework - Many to Many Subquery

    - by Jorin
    I asked a question about this previously but my database structure has changed, and while it made other things simpler, now this part is more complicated. Here is the previous question. At the time, my EF Context had a UsersProjects object because there were other properties. Now that I've simplified that table, it is just the keys, so all my EF context knows about is Users and Projects and the M2M relationship between them. There is no more UsersProjects as far as EF knows. So my goal is to say "show me all the users who are working on projects with me." in SQL, this would go something like: SELECT * FROM Users INNER JOIN UsersProjects ON Users.ID=UsersProjects.UserID WHERE ProjectID IN (SELECT ProjectID FROM UsersProjects WHERE UserID=@UserID) and I started in EF with something like this: var myProjects = (from p in edmx.Projects where p.Users.Contains(edmx.Users.FirstOrDefault(u => u.Email == UserEmail)) orderby p.Name select p).ToList(); var associatedUsers = (from u in edmx.Users where myProjects.Contains(?????????) //where myProjects.Any(????????) select u); The trick is finding what to put in the ????????. Anyone help here?

    Read the article

  • Django install on a shared host, .htaccess help

    - by redconservatory
    I am trying to install Django on a shared host using the following instructions: docs.google.com/View?docid=dhhpr5xs_463522g My problem is with the following line on my root .htaccess: RewriteRule ^(.*)$ /cgi-bin/wcgi.py/$1 [QSA,L] When I include this line I get a 500 error with almost all of my domains on this account. My cgi-bin directory is home/my-username/public_html/cgi-bin/ The wcgi.py file contains: #!/usr/local/bin/python import os, sys sys.path.insert(0, "/home/username/django/") sys.path.insert(0, "/home/username/django/projects") sys.path.insert(0, "/home/username/django/projects/newprojects") import django.core.handlers.wsgi os.chdir("/home/username/django/projects/newproject") # optional os.environ['DJANGO_SETTINGS_MODULE'] = "newproject.settings" def runcgi(): environ = dict(os.environ.items()) environ['wsgi.input'] = sys.stdin environ['wsgi.errors'] = sys.stderr environ['wsgi.version'] = (1,0) environ['wsgi.multithread'] = False environ['wsgi.multiprocess'] = True environ['wsgi.run_once'] = True application = django.core.handlers.wsgi.WSGIHandler() if environ.get('HTTPS','off') in ('on','1'): environ['wsgi.url_scheme'] = 'https' else: environ['wsgi.url_scheme'] = 'http' headers_set = [] headers_sent = [] def write(data): if not headers_set: raise AssertionError("write() before start_response()") elif not headers_sent: # Before the first output, send the stored headers status, response_headers = headers_sent[:] = headers_set sys.stdout.write('Status: %s\r\n' % status) for header in response_headers: sys.stdout.write('%s: %s\r\n' % header) sys.stdout.write('\r\n') sys.stdout.write(data) sys.stdout.flush() def start_response(status,response_headers,exc_info=None): if exc_info: try: if headers_sent: # Re-raise original exception if headers sent raise exc_info[0], exc_info[1], exc_info[2] finally: exc_info = None # avoid dangling circular ref elif headers_set: raise AssertionError("Headers already set!") headers_set[:] = [status,response_headers] return write result = application(environ, start_response) try: for data in result: if data: # don't send headers until body appears write(data) if not headers_sent: write('') # send headers now if body was empty finally: if hasattr(result,'close'): result.close() runcgi() Only I changed the "username" to my username...

    Read the article

  • How do you tell that your unit tests are correct?

    - by Jacob Adams
    I've only done minor unit testing at various points in my career. Whenever I start diving into it again, it always troubles me how to prove that my tests are correct. How can I tell that there isn't a bug in my unit test? Usually I end up running the app, proving it works, then using the unit test as a sort of regression test. What is the recommended approach and/or what is the approach you take to this problem? Edit: I also realize that you could write small, granular unit tests that would be easy to understand. However, if you assume that small, granular code is flawless and bulletproof, you could just write small, granular programs and not need unit testing. Edit2: For the arguments "unit testing is for making sure your changes don't break anything" and "this will only happen if the test has the exact same flaw as the code", what if the test overfits? It's possible to pass both good and bad code with a bad test. My main question is what good is unit testing since if your tests can be flawed you can't really improve your confidence in your code, can't really prove your refactoring worked, and can't really prove that you met the specification?

    Read the article

  • Typical Hadoop setup for remote job submission

    - by Artii
    So I am still a bit new to hadoop and am currently in the process of setting up a small test cluster on Amazonaws. So my question relates to some tips on the structuring of the cluster so it is possible to work submit jobs from remote machines. Currently I have 5 machines. 4 are basically the Hadoop cluster with the NameNodes, Yarn etc. One machine is used as a manager machine( Cloudera Manager). I am gonna describe my thinking process on the setup and if anyone can chime in the points I am not clear with, that would be great. I was thinking what was the best setup for a small cluster. So I decided to expose only one manager machine and probably use that to submit all the jobs through it. The other machines will see each other etc, but not be accessible from the outside world. I am have conceptual idea on how to do this,but I am not sure how to properly go about doing this though, if anyone could point me in the right direction that would great. Also another big point is, I want to be able to submit jobs to the cluster through exposed machine from a client machine (might be Windows). I am not so clear on this setup as well. Do I need to have Hadoop installed on the machine in order to use the normal hadoop commands, and to write/submit jobs say from Eclipse or something similar. So to sum it up my questions are, Is this an ok setup for a small test cluster How can I go about using one exposed machine to submit/route jobs to the cluster, without having any of the Hadoop nodes on it. How do I setup a client machine to submit jobs to a remote cluster, and an example on how to do it on Windows. Also if there are any reason not to use Windows as a client machine in this setup. Thanks I would greatly appreciate any advice or help on this.

    Read the article

  • Accessing data entered into multiple Django forms and generating them onto a new URL

    - by pedjk
    I have a projects page where users can start up new projects. Each project has two forms. The two forms are: class ProjectForm(forms.Form): Title = forms.CharField(max_length=100, widget=_hfill) class SsdForm(forms.Form): Status = forms.ModelChoiceField(queryset=P.ProjectStatus.objects.all()) With their respective models as follows: class Project(DeleteFlagModel): Title = models.CharField(max_length=100) class Ssd(models.Model): Status = models.ForeignKey(ProjectStatus) Now when a user fills out these two forms, the data is saved into the database. What I want to do is access this data and generate it onto a new URL. So I want to get the "Title" and the "Status" from these two forms and then show them on a new page for that one project. I don't want the "Title" and "Status" from all the projects to show up, just for one project at a time. If this makes sense, how would I do this? I'm very new to Django and Python (though I've read the Django tutorials) so I need as much help as possible. Thanks in advance Edit: The ProjectStatus code is (under models): class ProjectStatus(models.Model): Name = models.CharField(max_length=30) def __unicode__(self): return self.Name

    Read the article

  • I get NaN when I try to insert some HTML into a DIV element with jQuery

    - by Ankur
    I am tring to display a text box when a element of class numObj is clicked. For some reason I get NaNNaNaNaNNaNNaNaNaN where I expect to the see the result of the searchForm variable in the code below. I know that NaN stands for Not a Number. What I don't understand is why is Javascript expecting a number? I can't understand why it cares. $(".numObj").live('click',function(){ var preId = $(this).attr('preId'); var arrayPos = $(this).attr('numArrayPos'); alert(preId +" "+arrayPos); var searchForm = "<table border='0' cellspacing='0' cellpadding='4' id='add-tag2'>"+ +"<tr class='normal'><td bgcolor='#EEEEEE' valign='bottom' nowrap='nowrap'><span class='normal-small'>"+ +"<input name='predicate-name2' type='text' class='normal' id='predicate-name2' size='4' />"+ +"</span></td>"+ +"<td bgcolor='#EEEEEE' valign='bottom' nowrap='nowrap'><span class='normal-small'>&lt;=</span></td>"+ +"<td bgcolor='#EEEEEE' valign='bottom' nowrap='nowrap'>x</td>"+ +"<td valign='bottom' bgcolor='#EEEEEE'>&lt;=</td>"+ +"<td valign='bottom' bgcolor='#EEEEEE'><span class='normal-small'>"+ +"<input type='text' name='object-object2' id='object-object2' class='normal' size='4' />"+ +"</span></td>"+ +"</tr>"+ +"</table>"; $(".numObj").filter("[preId='"+preId+"']").filter("[numArrayPos='"+arrayPos+"']").html(searchForm); }); The generated code that has the numObj class looks something like this <td><div class="numObj" preid="73" numarraypos="5"><span class="normal">585.0</span></div></td>

    Read the article

  • Strategies for dealing with Circular references caused by JPA relationships?

    - by ams
    I am trying to partition my application into modules by features packaged into separate jars such as feature-a.jar, feature-b.jar, ... etc. Individual feature jars such as feature-a.jar should contain all the code for a feature a including jpa entities, business logic, rest apis, unit tests, integration test ... etc. The problem I am running into is that bi-directional relationships between JPA entities cause circular references between the jar files. For example Customer entity should be in customer.jar and the Order should be in order.jar but Customer references order and order references customer making it hard to split them into separate jars / eclipse projects. Options I see for dealing with the circular dependencies in JPA entities: Option 1: Put all the entities into one jar / one project Option 2: Don't map certain bi-directianl relationships to avoid circular dependencies across projects. Questions: What rules / principles have you used to decide when to do bi-directional mapping vs. not? Have you been able to break jpa entities into their own projects / jar by features if so how did you avoid the circular dependencies issues?

    Read the article

  • This code is not submitting to a form? Why

    - by Ankur
    Since I am using get I expect to see the submitted values appended to the queryString but instead all I see is the URL of the servlet being called with nothing added at the end. <form id="editClassList" name="editClassList" method="get" action="EditClassList"> <% HashMap<Integer,String> classes = new HashMap<Integer,String>(); classes = (HashMap<Integer,String>) request.getAttribute("classes"); %> <% if(classes.size()==0){ %> <label><input class="small-link" type="text" id="add-this-class" size="42" value="" /></label> <% } %> <% Set<Integer> classIds = new HashSet<Integer>(); classIds = classes.keySet(); Iterator<Integer> itr = classIds.iterator(); while(itr.hasNext()){ int nextId = (Integer)itr.next(); %> <label><input class="small-link" type="text" id="<% out.print(nextId); %>" size="42" value="<% out.print(classes.get(nextId)); %>" /> </label> <img id="add-class" src="images/add.png" width="16" height="16" /><br /> <label><input class="small-link" type="text" id="class-to-add" size="42" value="" /></label> <% } %> <label><input type="submit" id="save-class-btn" value="Save Class(es)" /></label> </form>

    Read the article

  • ASP.NET Web Application: use 1 or multiple virtual directories

    - by tster
    I am working on a (largish) internal web application which has multiple modules (security, execution, features, reports, etc.). All the pages in the app share navigation, CSS, JS, controls, etc. I want to make a single "Web Application" project, which includes all the pages for the app, then references various projects which will have the database and business logic in them. However, some of the people on the project want to have separate projects for the pages of each module. To make this more clear, this is what I'm advocating to be the projects. /WebInterface* /SecurityLib /ExecutionLib etc... And here is what they are advocating: /SecurityInterface* /SecutiryLib /ExecutionInterface* /ExecutionLib etc... *project will be published to a virtual directory of IIS Basically What I'm looking for is the advantages of both approaches. Here is what I can think of so far: Single Virtual Directory Pros Modules can share a single MasterPage Modules can share UserControls (this will be common) Links to other modules are within the same Virtual directory, and thus don't need to be fully qualified. Less chance of having incompatible module versions together. Multiple Virtual Directories Pros Can publish a new version of a single module without disrupting other modules Module is more compartmentalized. Less likely that changes will break other modules. I don't buy those arguments though. First, using load balanced servers (which we will have) we should be able to publish new versions of the project with zero downtime assuming there are no breaking database changes. Second, If something "breaks" another module, then there is either an improper dependency or the break will show up eventually in the other module, when the developers copy over the latest version of the UserControl, MasterPage or dll. As a point of reference, there are about 10 developers on the project for about 50% of their time. The initial development will be about 9 months.

    Read the article

  • How to improve Visual C++ compilation times?

    - by dtrosset
    I am compiling 2 C++ projects in a buildbot, on each commit. Both are around 1000 files, one is 100 kloc, the other 170 kloc. Compilation times are very different from gcc (4.4) to Visual C++ (2008). Visual C++ compilations for one project take in the 20 minutes. They cannot take advantage of the multiple cores because a project depend on the other. In the end, a full compilation of both projects in Debug and Release, in 32 and 64 bits takes more than 2 1/2 hours. gcc compilations for one project take in the 4 minutes. It can be parallelized on the 4 cores and takes around 1 min 10 secs. All 8 builds for 4 versions (Debug/Release, 32/64 bits) of the 2 projects are compiled in less than 10 minutes. What is happening with Visual C++ compilation times? They are basically 5 times slower. What is the average time that can be expected to compile a C++ kloc? Mine are 7 s/kloc with vc++ and 1.4 s/kloc with gcc. Can anything be done to speed-up compilation times on Visual C++?

    Read the article

  • How to extract ALL typedefs and structs and unions from c++ source

    - by Michael Wells
    I have inherited a Visual Studio project that contains hundreds of files. I would like to extract all the typedefs, structs and unions from each .h/.cpp file and put the results in a file). Each typdef/struct/union should be on one line in the results file. This would make sorting much easier. typdef int myType; struct myFirstStruct { char a; int b;...}; union Part_Number_Serial_Number_Part_2_Response_Message_Type {struct{Message_Response_Head_Type Head; Part_Num_Serial_Num_Part_2_Report_Array Part_2_Report; Message_Tail_Type Tail;} Data; BYTE byData[140];}myUnion; struct { bool c; int d;...}mySecondStruct; My problem is, I do not know what to look for (grammar of typedef/structs/unions) using a regular expression. I cannot believe that nobody has done this before (I googled and have not found anything on this). Does anyone know the regular expressions for these? (Note some are commented out using // others /* */) Or a tool to accomplish this. Edit: I am toying with the idea of autogenerating source code and/or dialogs for modifying messages that use the underlying typedef/struct/union. I was going to use the output to generate an XML file that could be used for this reason. The source for these are in C/C++ and used in almost all my projects. These projects are usually NOT in C/C++. By using the XML version I would only need to update/add the typedef/struct/union only in one place and all the projects would be able to autogen the source and/or dialogs.

    Read the article

  • How to invoke make install for one subdirectory of Qt project

    - by chalup
    I'm working on custom library and I wish users could just use it by adding: CONFIG += mylib to their pro files. This can be done by installing mylib.prf file to %QTDIR%/mkspec/features. I've checked out in Qt Mobility project how to create and install such file, but there is one thing I'd like to do differently. If I correctly understood the pro/pri files of Qt Mobility, inside the example projects they don't really use CONFIG += mobility, instead they add QtMobility sources to include path and share the *.obj directory with main library project. For my library I'd like to have examples that are as independent projects as possible, i.e. projects that can be compiled from anywhere once MyLib is compiled and installed. I have following directory structure: mylib | |- examples |- src |- tests \- mylib.pro It seems that the easiest way to achieve what I described above is creating mylib.pro like this: TEMPLATE = subdirs SUBDIRS += src SUBDIRS += examples tests:SUBDIRS += tests And somehow enforce invoking "cd src && make install" after building src. What is the best way to do this? Of course any other suggestions for automatic library deployment before examples compilation are welcome.

    Read the article

  • Subversion freaking out on me!

    - by Malfist
    I have two copies of a site, one is the production copy, and the other is the development copy. I recently added everything in the production to a subversion repository hosted on our linux backup server. I created a tag of the current version and I was done. I then copied the development copy overtop of the production copy (on my local machine where I have everything checked out). There are only 10-20 files changed, however, when I use tortoise SVN to do a commit, it says every file has changed. The diff file generated shows subversion removing everything, and replacing it with the new version (which is the exact same). What is going on? How do I fix it? An example diff: Index: C:/Users/jhollon/Documents/Visual Studio 2008/Projects/saloon/trunk/components/index.html =================================================================== --- C:/Users/jhollon/Documents/Visual Studio 2008/Projects/saloon/trunk/components/index.html (revision 5) +++ C:/Users/jhollon/Documents/Visual Studio 2008/Projects/saloon/trunk/components/index.html (working copy) @@ -1,4 +1,4 @@ -<html> -<body bgcolor="#FFFFFF"> -</body> +<html> +<body bgcolor="#FFFFFF"> +</body> </html> \ No newline at end of file

    Read the article

  • C# 3 dimensional array definition issue

    - by George2
    Hello everyone, My following code has compile error, Error 1 Cannot implicitly convert type 'TestArray1.Foo[,,*]' to 'TestArray1.Foo[][][]' C:\Users\lma\Documents\Visual Studio 2008\Projects\TestArray1\TestArray1\Program.cs 17 30 TestArray1 Does anyone have any ideas? Here is my whole code, I am using VSTS 2008 + Vista 64-bit. namespace TestArray1 { class Foo { } class Program { static void Main(string[] args) { Foo[][][] foos = new Foo[1, 1, 1]; return; } } } EDIT: version 2. I have another version of code, but still has compile error. Any ideas? Error 1 Invalid rank specifier: expected ',' or ']' C:\Users\lma\Documents\Visual Studio 2008\Projects\TestArray1\TestArray1\Program.cs 17 41 TestArray1 Error 2 Invalid rank specifier: expected ',' or ']' C:\Users\lma\Documents\Visual Studio 2008\Projects\TestArray1\TestArray1\Program.cs 17 44 TestArray1 namespace TestArray1 { class Foo { } class Program { static void Main(string[] args) { Foo[][][] foos = new Foo[1][1][1]; return; } } } EDIT: version 3. I think I want to have a jagged array. And after learning from the fellow guys. Here is my code fix, and it compile fine in VSTS 2008. What I want is a jagged array, and currently I need to have only one element. Could anyone review whether my code is correct to implement my goal please? namespace TestArray1 { class Foo { } class Program { static void Main(string[] args) { Foo[][][] foos = new Foo[1][][]; foos[0] = new Foo[1][]; foos[0][0] = new Foo[1]; foos[0][0][0] = new Foo(); return; } } } thanks in advance, George

    Read the article

  • Web page for IPhone - Large fonts instead of scrolling?

    - by chris_l
    I'm planning the layout of my web page, which should also be usable on the IPhone. I don't really have much experience with the IPhone yet - I just installed the IPhone Simulator on my Mac. The page's contents are flexible, so I think it would be better to use this flexibility to avoid that the user has to scroll around the entire page. Especially I have A header and a sidebar that will be used all the time to perform several actions. A main content area with a number of elements (e.g. images). The UI would stay usable pretty well, if the number of elements shown at one time is reduced for a small screen (e.g. by JavaScript). It would also be okay to make the main content area scrollable (as opposed to the entire page). The problem: If I simply display the page on the IPhone, it uses an extremely small font size, so that users must zoom in first, and then scroll around - so that they can't see the header and sidebar all the time. What's the best way to deal with this situation? Just leave it this way (very small fonts), because users expect that behaviour on the IPhone? Increase the font size (by specifying it in em or px or with xx-large, or what would be the best way?), if I detect - somehow - that it's being displayed on the IPhone. Or is there some way to restrict the viewport size to the screen size, and make it zoom in automatically? I think that would be the easiest solution in my case. Or ...?

    Read the article

  • What should a teen dev do for practical experience in development?

    - by aviraldg
    What should a teen dev do for practical experience? If you want more details , then read on: I learnt programming when I was 9 , with GWBASIC (which I now hate) , which was what was taught @ school. That was done in a month. After that I learnt C++ and relearnt it (as I didn't know of templates and the STL before that) Recently I learnt PHP , SQL and Python. This was around the time I switched over to Ubuntu. I'd always loved the "GNUish" style of software development so I jumped right in. However , most of the projects that I found required extensive knowledge of their existing codebase. So , right now I'm this guy who knows a couple of languages and has written a couple of small programs ... but hasn't gone "big", if you get it. I would love suggestions of projects that are informal and small to medium sized , and do not require much knowledge of the codebase. Also note that I've looked at things like Google Summer of Code and sites like savannah.gnu.org and the first doesn't apply , since I'm still in school and the latter either has infeasable projects , or things that are too hard.

    Read the article

  • C# code simple console program not working

    - by Wast334
    I am trying to test some console ability in C#.. I can't get this code to work using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 { class Program { static void Main(string[] args) { Dim myMessage; myMessage = @"Hello World"; printf(@"%@", myMessage); return 0; } } } I am getting a bunch of compiler errors i am not sure what I am doing wrong..? Error 1 The type or namespace name 'Dim' could not be found (are you missing a using directive or an assembly reference?) C:\Documents and Settings\wstevens\Local Settings\Application Data\Temporary Projects\ConsoleApplication1\Program.cs 12 13 ConsoleApplication1 Error 2 The name 'printf' does not exist in the current context C:\Documents and Settings\wstevens\Local Settings\Application Data\Temporary Projects\ConsoleApplication1\Program.cs 14 13 ConsoleApplication1 Error 3 Since 'ConsoleApplication1.Program.Main(string[])' returns void, a return keyword must not be followed by an object expression C:\Documents and Settings\wstevens\Local Settings\Application Data\Temporary Projects\ConsoleApplication1\Program.cs 15 13 ConsoleApplication1

    Read the article

  • Cakephp 1.3, Weird behavior on firefox when using $this->Html->link ...

    - by ion
    Greetings, I am getting a very weird and unpredictable result in firefox when using the following syntax: $this->Html->link($this->Html->div('p-cpt',$project['Project']['name']) . $this->Html->div('p-img',$this->Html->image('/img/projects/'.$project['Project']['slug'].'/project.thumb.jpg', array('alt'=>$project['Project']['name'],'width'=>100,'height'=>380))),array('controller' => 'projects', 'action' => 'view', $project['Project']['slug']),array('title' => $project['Project']['name'], 'escape' => false),false); OK I know it is big but bear with me. The point is to get the following output: <a href="x" title="x"> <div class="p-ctp">Name</div> <div class="p-img"><img src="z width="y" height="a" alt="d" /></div> </a> I'm not sure if this validates correctly both on cakephp and html but it works everywhere else apart from firefox. You can actually see the result here: http://www.gnomonconstructions.com/projects/browser To reproduce the result use the form with different categories and press search. At some point it will happen!! Although most of the time it renders the way it should, sometimes it produces an invalid output like that: <a href="x" title="x"></a> <div class="p-cpt"> <a href="x" title="x">name</a> </div> <div class="p-img"> <a href="x" title="x"><img src="x" width="x" height="x" alt="x" /></a> </div> Looks like it repeats the link inside each element. To be honest the only reason I used this syntax was because cakephp encourages it. Any help will be much appreciated :)

    Read the article

  • Looking for an issue tracker / project management software that automatically manages start/completion dates based on priority/relationships

    - by user361910
    So, a little background. We are a small company with a half-dozen developers. We have been evaluating many project management / issue tracking software packages (TRAC, Redmine, FogBugz, etc) and trying to create a decent process/workflow for managing projects, adding features, fixing bugs, etc. I'd like to think our requirements are similar to most other companies our size. Essentially, what this comes down to is 1) An easy way for the PM and developers to track projects, issues, bugs, etc 2) An easy way for the PM and admin/executives to get a birds-eye view of progress and easily manage timelines, schedules, and priorities. After trying TRAC, we moved to Redmine. We found Redmine to be easier than track to administer and the ability to have sub-projects and sub-tickets is great. However, the big problem we ran into is the fact that it is very difficult to manage schedules and timelines. It seems like it would be incredibly time-intensive to manage because you have to manually enter a start date, estimated time, and end date for each ticket, project, etc. So if you setup a month's schedule based on priorities, what are you supposed to do when a particular ticket/issue/subproject takes up more time than was estimated. Right now, it appears I would have to go back in and MANUALLY change the start/end date of every single item. What would be ideal is to be able to set priorities/dependencies and estimated time on tickets/milestones, and have the software automatically manage the start/end dates. Does anyone know how to get Redmine to do this, or recommend a different software package that can do something like this!

    Read the article

  • Too many columns to index - use mySQL Partitions?

    - by Christopher Padfield
    We have an application with a table with 20+ columns that are all searchable. Building indexes for all these columns would make write queries very slow; and any really useful index would often have to be across multiple columns increasing the number of indexes needed. However, for 95% of these searches, only a small subset of those rows need to be searched upon, and quite a small number - say 50,000 rows. So, we have considered using mySQL Partition tables - having a column that is basically isActive which is what we divide the two partitions by. Most search queries would be run with isActive=1. Most queries would then be run against the small 50,000 row partition and be quick without other indexes. Only issue is the rows where isActive=1 is not fixed; i.e. it's not based on the date of the row or anything fixed like that; we will need to update isActive based on use of the data in that row. As I understand it that is no problem though; the data would just be moved from one partition to another during the UPDATE query. We do have a PK on id for the row though; and I am not sure if this is a problem; the manual seemed to suggest the partition had to be based on any primary keys. This would be a huge problem for us because the primary key ID has no basis on whether the row isActive.

    Read the article

  • jQuery .height() property not working

    - by Andrew
    I'm attempting to get the height of an element using jQuery, but am receiving some unexpected results. Here's the code: $(function() { var contentheight = $('#subpage-content-small').height; alert(contentheight); }); Where #subpage-content-small has these CSS properties: #subpage-content-small { width: 400px; float: left; margin: 30px 10px 0 0; padding-bottom: 45px; } What I'm getting as an output for my alert is the following: function (f) { var e = this[0]; if (!e) { return f == null ? null : this; } if (c.isFunction(f)) { return this.each(function (j) {var i = c(this);i[d](f.call(this, j, i[d]()));}); } return "scrollTo" in e && e.document ? e.document.compatMode === "CSS1Compat" && e.document.documentElement["client" + b] || e.document.body["client" + b] : e.nodeType === 9 ? Math.max(e.documentElement["client" + b], e.body["scroll" + b], e.documentElement["scroll" + b], e.body["offset" + b], e.documentElement["offset" + b]) : f === w ? c.css(e, d) : this.css(d, typeof f === "string" ? f : f + "px"); } Any idea why I'm getting this as opposed to an integer of the height? Thanks in advance!

    Read the article

  • Python NameError when attempting to use a user-defined class

    - by Michael Herold
    I'm getting a weird instance of a NameError when attempting to use a class I wrote. In a directory, I have the following file structure: dir/ ReutersParser.py test.py reut-xxx.sgm Where my custom class is defined in ReutersParser.py and I have a test script defined in test.py. The ReutersParser looks something like this: from sgmllib import SGMLParser class ReutersParser(SGMLParser): def __init__(self, verbose=0): SGMLParser.__init__(self, verbose) ... rest of parser if __name__ == '__main__': f = open('reut2-short.sgm') s = f.read() p = ReutersParser() p.parse(s) It's a parser to deal with SGML files of Reuters articles. The test works perfectly. Anyway, I'm going to use it in test.py, which looks like this: from ReutersParser import ReutersParser def main(): parser = ReutersParser() if __name__ == '__main__': main() When it gets to that parser line, I'm getting this error: Traceback (most recent call last): File "D:\Projects\Reuters\test.py", line 34, in <module> main() File "D:\Projects\Reuters\test.py", line 19, in main parser = ReutersParser() File "D:\Projects\Reuters\ReutersParser.py", line 38, in __init__ SGMLParser.__init__(self, verbose) NameError: global name 'sgmllib' is not defined For some reason, when I try to use my ReutersParser in test.py, it throws an error that says it cannot find sgmllib, which is a built-in module. I'm at my wits' end trying to figure out why the import won't work. What's causing this NameError? I've tried importing sgmllib in my test.py and that works, so I don't understand why it can't find it when trying to run the constructor for my ReutersParser.

    Read the article

< Previous Page | 135 136 137 138 139 140 141 142 143 144 145 146  | Next Page >