Search Results

Search found 3678 results on 148 pages for 'weird'.

Page 88/148 | < Previous Page | 84 85 86 87 88 89 90 91 92 93 94 95  | Next Page >

  • htaccess redirect conditions

    - by user271619
    I figured out how to redirect someone, if they happen across one particular filename: Redirect /index.php http://www.website.com/#myaccount As you can see, I'm pretty much redirecting that visitor to the same page, which doesn't work. It's an endless look, regardless of the slight/minuscule change. I want to force someone to see a part of the page, by adding the hash. (it's a little weird, I know) I'm guessing this may be a time to use regex in the htaccess file. But I thought I'd ask if there's a simpler way to do this from the htaccess file.

    Read the article

  • empty() returning TRUE on object's non-empty property

    - by Michal M
    I've got a very weird and unexpected problem. empty() is returning TRUE on a non-empty property for a reason unknown to me. class MyObject { private $_property; public function __construct($property) { $this->_property = $property; } public function __get($name) { $priv_name = "_{$name}"; if (isset($this->$priv_name)) { return $this->$priv_name; } else { return NULL; } } } $obj = new MyObject('string value'); echo $obj->property; // Output 'string value' echo empty($obj->property); // Output 1 (means, that property is empty) Would this mean, that the __get() magic function is not called when using empty()? btw. I'm running PHP version 5.0.4

    Read the article

  • Arguments to convince to switch from CVS to SVN

    - by ereOn
    Hi, The UNIX department of my company currently uses CVS as source-version control system. They use it in a very strange way: different repositories for development/testing/production code (for the same project), no one tags anything, weird directory architecture, and so on. The system has been set for ages but now, I have an opportunity to organize a meeting where I have to suggest changes. I'd like to make them change from CVS to SVN (Mercurial or Git might be even better, however I can't really recommand using a system I don't know well, and switching to SVN will already be a great step forward). I don't have much experience with CVS so I can't compare them efficiently: I just know it doesn't support atomic operations and that it is deprecated. What killer arguments would you use to convince my collegues to do the switch ? Thank you very much.

    Read the article

  • How do you debug c/c++ source code in linux using emacs?

    - by vmihai
    Hello all, I am using emacs and autotools, to write and compile c/c++ sources on linux. I am using gdb via GUD in emacs. I have defined for convenience: F7:compile, F10:gud-next, F11:gud-step, F5:gud-cont, F9:gud-tbreak, F8:gud-until, F4:gud-print. I am mainly interested in debugging c/c++ source code on linux from emacs and I would like to get the most gdb can give. Unfortunately I am using only F4 which prints the variable under cursor. So my question is how do you guys debug the source code ? What programs do you use ? What key bindings (functionality) do you use mostly ? What do you need the debugger to do for you ? If you do weird stuff it doesn't matter. I would like to know everything to boost my speed a bit here. Thanks in advance. Mihai

    Read the article

  • sqrt(int_value + 0.0) ? The point?

    - by Earlz
    Hello, while doing some homework in my very strange C++ book, which I've been told before to throw away, had a very peculiar code segment. I know homework stuff always throws in extra "mystery" to try to confuse you like indenting 2 lines after a single-statement for-loop. But this one I'm confused on because it seems to serve some real-purpose. basically it is like this: int counter=10; ... if(pow(floor(sqrt(counter+0.0)),2) == counter) ... I'm interested in this part especially: sqrt(counter+0.0) Is there some purpose to the +0.0? Is this the poormans way of doing a static cast to a double? Does this avoid some compiler warning on some compiler I do not use? The entire program printed the exact same thing and compiled without warnings on g++ whenever I left out the +0.0 part. Maybe I'm not using a weird enough compiler?

    Read the article

  • How to get image from relative URL in C#, the image cannot be in the project

    - by red-X
    I have a project where I'm loading relative image Uri's from an xml file. I'm loading the image like this: if (child.Name == "photo" && child.Attributes["href"] != null && File.Exists(child.Attributes["href"].Value)) { Image image = new Image(); image.Source = new BitmapImage(new Uri(child.Attributes["href"].Value, UriKind.RelativeOrAbsolute)); images.Add(image); } Where the "child" object is an XmlNode which could looks like this <photo name="info" href="Resources\Content\test.png"/> During debug it seemd images is filled with actual images but when I want to see them in any way it shows nothing. Weird thing is when I include the images in my project it does work, I however dont want to do that since my point for using an xml file is so that it would be lost since you'd have to rebuild the program anyway after a change.

    Read the article

  • std::string constructor corrupts pointer

    - by computergeek6
    I have an Entity class, which contains 3 pointers: m_rigidBody, m_entity, and m_parent. Somewhere in Entity::setModel(std::string model), it's crashing. Apparently, this is caused by bad data in m_entity. The weird thing is that I nulled it in the constructor and haven't touched it since then. I debugged it and put a watchpoint on it, and it comes up that the m_entity member is being changed in the constructor for std::string that's being called while converting a const char* into an std::string for the setModel call. I'm running on a Mac, if that helps (I think I remember some problem with std::string on the Mac). Any ideas about what's going on?

    Read the article

  • C pointer array scope and function calls

    - by juvenis
    I have this situation: { float foo[10]; for (int i = 0; i < 10; i++) { foo[i] = 1.0f; } object.function1(foo); // stores the float pointer to a const void* member of object } object.function2(); // uses the stored void pointer Are the contents of the float pointer unknown in the second function call? It seems that I get weird results when I run my program. But if I declare the float foo[10] to be const and initialize it in the declaration, I get correct results. Why is this happening?

    Read the article

  • varchar data type to datetime data type resulted in an out-of-range??

    - by leen3o
    Very weird problem occurred, I have moved a site from one server to another - All is working, but any query involving a date is playing up. I get the following: DELETE FROM MYTABLE WHERE categoryId = -2 AND datecreated < '3/23/2010'; The conversion of a varchar data type to a datetime data type resulted in an out-of-range value Now what's strange is I have changed the LCID to 1033 on the new server as the date is showing as US format and its still throwing an error! I then tried 2057 and again the same error? Made no difference. I'm a little confused, as this is a working site from a server with IIS6 - The locale is 1033 on that server and it works perfectly!! :S I have just tried thrown a Cdate() around the date too and yet again the same error??? Any ideas??

    Read the article

  • Escaping Problem in bash using isql

    - by latz
    Hi there, I am currently working on a little backup script from some firebird databases and I've come up with a weird escaping problem that I don't seem to be able to solve. Here's the thing in my script I create a variable called sqllog in which I would like to put the output of a chain of commands, here it is. sqllog=echo "SELECT * FROM RDB\$DATABASE;" | isql -u SYSDBA -pass mypasswd localhost:mydatabase | tail -n 2 | head -n 1 | wc -l if I try to execute this in shell I get the following error Statement failed, SQLCODE = -204 Dynamic SQL Error -SQL error code = -204 -Table unknown -RDB -At line 1, column 15. Table unknown RDB means it didn't take my try to escape the $. thx for any help :)

    Read the article

  • Losing scope for DataContex using LINQToSQL intermediately

    - by greektreat
    I am having a weird Situation with my DataConext. All My code is in C# I have a DLL project for my data access layer and business Layer which and Winforms project for my UI layer. My Data access Layer's Namespace is xxx.Data this is where have my xxx.dbml I also have xxx.Data.BusinessObjects name space of course for my business object in that project In my UI Layer I have these namespaces xxxApp(for Forms), xxxApp.Controls (For Controls) I have lost scope of the DataContext, it was accessible now when I do a Rebuild Solution I sometimes get compile errors saying for example: Error 34 'xxx.Data.xxxDataContext' does not contain a definition for 'SubmitChanges' and no extension method 'SubmitChanges' accepting a first argument of type 'xxx.Data.xxxDataContext' could be found (are you missing a using directive or an assembly reference?) Also intelisense doesn't recognize the methods and table classes from my xxxDataContext anymore I can access all object fine when I am in the DLL project but now in the Winforms project this is very strange. If anyone can help me out I would be extremely grateful!

    Read the article

  • How to slow down Uploadify plugin script voor jQuery

    - by Peter
    Now if that isn't a weird question, I don't know what is. But here is the problem: I have a function in my "onSelect" option that has to collect some data (through AJAX) and I have a function in my "onComplete" option that processes the just uploaded files based on the data "onSelect" collected. However, with very small files, the "onSelect" hasn't finished yet before the upload is complete and the "onComplete" fails because it lacks the necessary data. Bigger files work just fine. So, I'm looking for a way to stall the upload of the file. To let it start only after the function in onSelect completed fetching the necessary data. Any ideas? Here is an example of the function that the onSelect triggers: var foo = new Array(); function checkDB( event, queueID , fileObj ) { $.post( ajax_folder + 'fetchData' , { ref: "someValue" } , function( data ){ foo[ queueID ] = data.result; } , 'json' ); return true; }

    Read the article

  • How does DateTime.Now.Tick exactly work?

    - by Roflcoptr
    In my application I generate files at random opportunities. To ensure a unique naming, I tried to use the nano seconds since 1.1.1970: long time = DateTime.Now.Ticks; String fileName = Convert.ToString(time); Console.WriteLine(fileName); Now I observed something weird. Why is the output like that? I mean why are the last 4 numbers always the same? I can use this as a filename, that is not the problem, but I'm just wondering about it. 634292263478068039 634292263512888039 634292263541368039 634292263603448039 634292263680078039

    Read the article

  • Passing the "enter key" event to flash player in an ATL Window?

    - by Adam Naylor
    I have a Flash player (flash9.ocx) embedded in an ATL window and have coded functionality into the swf to respond to the return/enter key being pressed. Works fine from the standalone swf player but as soon as its played from within my embedded player it doesn't execute. It's as if my window is getting in the way somehow? Is there any way to pass the keypress through to the player? FYI, there isn't anything to weird in place on the form. Thanks!

    Read the article

  • Google maps event problem with flex actionscript

    - by DEH
    I am able to render a google map on a flex canvas. I create the map using the code below and then place markers on it in the onMapReady method (not shown) var map:com.google.maps.Map=new com.google.maps.Map(); map.id="map"; map.key="bla bla"; _mapCanvas.addChild(map); map.addEventListener(MapEvent.MAP_READY,onMapReady); It all works fine. However, if I remove the map and then set _mapCanvas to null, then run exactly the same code again, the onMapReady event does not fire. It is weird, but once a map has been created and deleted, the onMapReady event never seems to fire again. Anyone got any ideas? Thanks.

    Read the article

  • SVN:Team member can checkout, commit; can't update

    - by Casey K.
    Hi all, got a weird problem for you: I've set up an svn server on a home machine, which is accessible to the members of my game team over DynDNS. So far so good- everyone was able to checkout the repo no problem. In addition, several team members and I were able to update and commit just fine. The conundrum is this: One of my team members, who is able to both checkout and commit, is unable to update. TortoiseSVN proffers: Error Could not open the requested SVN filesystem Has anyone dealt with this problem before? This isn't my first SVN rodeo, but I have to admit I'm stumped. Thanks!

    Read the article

  • "No row with the given identifier exists" although it DOES exist!

    - by roesslerj
    Hello all! I am using Hibernate and getting Exception in thread "main" org.hibernate.ObjectNotFoundException: No row with the given identifier exists: [<MyDbObject>#271] What is pretty weird about this error is, that the object with the given id exists in the database. I inserted the problematic record in another run of the application. If I access it in the same run (i.e. same hibernate session) there seem to be no problems retrieving the data. Just because it could be a fault of the mapping: public class ProblemClass { @ManyToOne(optional = false) private MyDbObject myDbObject; } public class MyDbObject { @OneToMany(mappedBy = "myDbObject") private List<ProblemClass> problemClasses; } I have absolutely no clue even where to look at. Any hints highly appreciated!

    Read the article

  • What is the best way to read files in an EventMachine-based app?

    - by Theo
    In order not to block the reactor I would like to read files asynchronously, but I've found no obvious way of doing it using EventMachine. I've tried a few different approaches, but none of them feels right: Just read the file, it'll block the reactor, but what the hell, it's not that slow (unless it's a big file, and then it definitely is). Open the file for reading and read a chunk on each tick (but how much to read? too much and it'll block the reactor, too little and reading will get slower than necessary). EM.popen('cat some/file', FileReader) feels really weird, but works better than the alternatives above. In combination with the LineAndTextProtocol it reads lines pretty swiftly. EM.attach, but I haven't found any examples of how to use it, and the only thing I've found on the mailing list is that it's deprecated in favour of… EM.watch, which I've found no examples of how to use for reading files. How do you read files within a EventMachine reactor loop?

    Read the article

  • Know if a Visual Studio Website project is recompiling itself in the background?

    - by jdk
    A number of team members update a central ASP.NET dev site (Website project, not a Web application type). Some kinds of changes cause a recompile/rebuild in it. The large website takes a while to recompile and we've noticed it will still seemingly serve out dynamic pages before everything is internally updated. During the site's "gestation" period, our mileage varies while hitting it. Sometimes we get a correct page, sometimes an compilation error page that will eventually be served up without a compilation error, and at other times an unexpected hybrid. Is it possible to query an ASP.NET website application to see if it's currently compiling or rebuilding itself? If so I would write a status page that the team could reference when they're getting weird behaviour, so they would know to wait. Update: Our team often edit files manually on the dev server. For production we'd make pre-compiled pushes. The dev environment is a little more malleable and ever-changing so I'm looking for a solution to reducing the "confusion" there.

    Read the article

  • Rendering inconsistencies in Internet Explorer

    - by gmunk
    Hello, I have some weird problem in rendering some xhtml in IE 8 http://img709.imageshack.us/i/scrj.png/. Here is the screenshot. As shown the greet me submit button is higher than the text field. Which is kind of odd. I checked with some other browsers and it works fine, it also works fine on Windows 7 with IE 8. Here is the code for the site: http://pastebin.com/cUkVA1HP http://pastebin.com/nU4cdpDE and the reset I'm using http://pastebin.com/uyEbAsEF I'm really puzzled by this strange behaviour. Thanks in advance for any ideas.

    Read the article

  • Gen folder disappearing in Eclipse Android project

    - by Adam Haile
    I'm just getting started developing for Android and I'm running into a weird problem. First off, I'm running Eclipse for Java devs v3.5.2 with the Android 2.1 SDK installed. Basically, whenever I do just about anything the "gen" (R.java, etc.) folder will just disappear from the project. I'm seen some people online say that it was still on the drive, just gone from the project listing in Eclipse, but in my case it is literally and completely gone. The only fix I've found is that if I refresh, then try to build, it gives an error and "gen" shows up in the project view (though it's not on the disk), then delete it from within the project, then Rebuild All and it will say that it cannot find it and is recreating it. Problem is, I have to do this every single time I want to build. There's got to be a fix for this.

    Read the article

  • Dynamic binary from file

    - by Aurel300
    This is a little bit of weird problem here. Say I have a C++ code, running on a specific platform. The only purpose of this code is to run files containing binary, NATIVE to that platform. Now - my question is - HOW would I get the data from these files (could even be by bits, like 1024 bits a cycle) to the memory of machine running my code so that this data would be in the execution part? In other words, can I get the data to somewhere where I can point the instruction pointer? If yes, how? I don't mind if I have to use assembler for this - just so it would work.

    Read the article

  • How to fit more operations to tab bar + navigation bar?

    - by Henry
    I want to use Tabview for my whole app. However in certain view, I have more operations than I can fit in the navigator bar. So I thought of using Toolbar but toolbar should be located at the bottom, right? Toolbar looks weird to be on top of the tabview, and hiding tabview for one view doesn't really make sense. I guess I can go with more buttons in the main view, but any other alternatives? What can one use to add more operation(s) to tabview? Thanks

    Read the article

  • Questions about "casting operation" in OOP

    - by rhapsodyn
    When programming, we usually use some type-casting operations. When the casting happens on the objects "on the same level", it feels ok. But when it happens on the ojects "on the different levels"(mainly between father and son), it feels weird. Considering this: Class Son extends Father WhenSon s = (Son)father;, it's absolutely unreasonable. Because a "Son" is not a "Father" anymore, "Son" may grow up with some new properties "Father" doesn't have, the casting operation makes these properties unknown. On the other hand, Father f = (Father)son seems reasonable, but according to LSP "An instance of a derived should be able to replace any instance of its superclass" A "Son" can do anything his "Father" can, so the casting operation seems useless. So can i say that these casting operations are agaisnt OO design principle but necessary?

    Read the article

  • Database Error django

    - by Megan
    DatabaseError at /admin/delmarva/event/ no such column: delmarva_event.eventdate I created a class in my models.py file: from django.db import models from django.contrib.auth.models import User class Event(models.Model): eventname = models.CharField(max_length = 100) eventdate = models.DateField() eventtime = models.TimeField() address = models.CharField(max_length = 200) user = models.ForeignKey(User) def __unicode__(self): return self.eventname and now when i try to view my events in my admin or my main_page it gives me the error that there is no eventdate. I tried syncing the db again but nothing changed. Also, I hashtagged eventdate out to see if I get a different error and then it states that delmarva_event.eventtime does not exist as well. I It is weird because it does not have a problem with eventname. Any suggestions would be greatly appreciated!

    Read the article

< Previous Page | 84 85 86 87 88 89 90 91 92 93 94 95  | Next Page >