Daily Archives

Articles indexed Sunday January 16 2011

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

  • How do I show a user's credit based on their session

    - by Jamie
    Hi all - I'm developing a simple LAMP app where users can credit their account using Paypal. I suspect this is a simple issue, but have spent quite a while experimenting to no avail and would appreciate any thoughts: System has a user management system working fine using sessions, but I can't get it to display the current user's credit. But I've been trying things along the lines of: $result = mysql_query(" SELECT * FROM users INNER JOIN account ON account.UserID=account.UserID ORDER BY account.accountID"); while($_SESSION['Username'] = $row['Username'] ) { echo $row['Username']; echo $row['Credit']; } I suspect the while statement is invalid, but I want it to echo username and credit where the current session username = the username stored in the database. Thanks so much for taking a look - very much appreciated.

    Read the article

  • search and replace with ruby regex

    - by randombits
    I have a text blob field in a MySQL column that contains HTML. I have to change some of the markup, so I figured I'll do it in a ruby script. Ruby is irrelevant here, but it would be nice to see an answer with it. The markup looks like the following: <h5>foo</h5> <table> <tbody> </tbody> </table> <h5>bar</h5> <table> <tbody> </tbody> </table> <h5>meow</h5> <table> <tbody> </tbody> </table> I need to change just the first <h5>foo</h5> block of each text to <h2>something_else</h2> while leaving the rest of the string alone. Can't seem to get the proper PCRE regex, using Ruby.

    Read the article

  • Need explaination of a php code snippet

    - by aqif hamid
    Hello, I have code that transloads files to your server. I tried reading this code but was unable to understand. Can any PHP Guru spend some time to understand this code and comment it. Please I need to understand this code to modify this. Modification required is: at the moment it transloads files from direct links that ends up with file extension. like. www.mysite.com?file.zip but it wont work for download links like www.mysite.com?download.php?fileid=3 I want it to work for all direct links. Code is downloadable from box.net from following url as well, http://www.box.net/shared/no21luo2m2 This url is itself eample of url for which I want this script to work. regards, aqif

    Read the article

  • How to determine the size (in bytes) of a file downloading using NSURLConnection?

    - by RexOnRoids
    I need to know the size of the file I am downloading (in bytes) into my app using NSURLConnection (GET). Here is my bytes recieved code below if it helps. What I need to know is how to get the filesize in bytes so that I can use it to show a UIProgressView. - (void)connection:(NSURLConnection *)theConnection didReceiveData:(NSData *)data // A delegate method called by the NSURLConnection as data arrives. We just // write the data to the file. { #pragma unused(theConnection) NSInteger dataLength; const uint8_t * dataBytes; NSInteger bytesWritten; NSInteger bytesWrittenSoFar; assert(theConnection == self.connection); dataLength = [data length]; dataBytes = [data bytes]; bytesWrittenSoFar = 0; do { bytesWritten = [self.fileStream write:&dataBytes[bytesWrittenSoFar] maxLength:dataLength - bytesWrittenSoFar]; assert(bytesWritten != 0); if (bytesWritten == -1) { [self _stopReceiveWithStatus:@"File write error"]; break; } else { bytesWrittenSoFar += bytesWritten; } while (bytesWrittenSoFar != dataLength); }

    Read the article

  • Java System.in issue

    - by theo
    `public static void main(String[] args) { Scanner sc = new Scanner(System.in); while (sc.hasNext()) { if (sc.next().equals("exit")){ System.out.println("EXITING"); System.exit(0); } else { System.out.println("IM STILL WORKING ok?"); } } } }` So here is a piece of code i was writing the other day to try and figure sth out (doesn't really matter what). The result of executing this code is : eIM STILL WORKING ok? eIM STILL WORKING ok? exit IM STILL WORKING ok? exit EXITING Can somebody kindly explain why this has happened?

    Read the article

  • Django Admin interface with pickled set

    - by Rosarch
    I have a model that has a pickled set of strings. (It has to be pickled, because Django has no built in set field, right?) class Foo(models.Model): __bar = models.TextField(default=lambda: cPickle.dumps(set()), primary_key=True) def get_bar(self): return cPickle.loads(str(self.__bar)) def set_bar(self, values): self.__bar = cPickle.dumps(values) bar = property(get_bar, set_bar) I would like the set to be editable in the admin interface. Obviously the user won't be working with the pickled string directly. Also, the interface would need a widget for adding/removing strings from a set. What is the best way to go about doing this? I'm not super familiar with Django's admin system. Do I need to build a custom admin widget or something? Update: If I do need a custom widget, this looks helpful: http://www.fictitiousnonsense.com/archives/22

    Read the article

  • Store comparison in variable (or execute comparison when it's given as an string)

    - by BorrajaX
    Hello everyone. I'd like to know if the super-powerful python allows to store a comparison in a variable or, if not, if it's possible calling/executing a comparison when given as an string ("==" or "!=") I want to allow the users of my program the chance of giving a comparison in an string. For instance, let's say I have a list of... "products" and the user wants to select the products whose manufacturer is "foo". He could would input something like: Product.manufacturer == "foo" and if the user wants the products whose manufacturer is not "bar" he would input Product.manufacturer != "bar" If the user inputs that line as an string, I create a tree with an structure like: != / \ manufacturer bar I'd like to allow that comparison to run properly, but I don't know how to make it happen if != is an string. The "manufacturer" field is a property, so I can properly get it from the Product class and store it (as a property) in the leaf, and well... "bar" is just an string. I'd like to know if I can something similar to what I do with "manufacturer": storing it with a 'callable" (kind of) thing: the property with the comparator: != I have tried with "eval" and it may work, but the comparisons are going to be actually used to query a MySQL database (using sqlalchemy) and I'm a bit concerned about the security of that... Any idea will be deeply appreciated. Thank you! PS: The idea of all this is being able to generate a sqlalchemy query, so if the user inputs the string: Product.manufacturer != "foo" || Product.manufacturer != "bar" ... my tree thing can generate the following: sqlalchemy.or_(Product.manufacturer !="foo", Product.manufacturer !="bar") Since sqlalchemy.or_ is callable, I can also store it in one of the leaves... I only see a problem with the "!="

    Read the article

  • jQuery: Highlight element under mouse cursor?

    - by Ralph
    I'm trying to create an "element picker" in jQuery, like Firebug has. Basically, I want to highlight the element underneath the user's mouse. Here's what I've got so far, but it isn't working very well: $('*').mouseover(function (event) { var $this = $(this); $div.offset($this.offset()).width($this.width()).height($this.height()); return false; }); var $div = $('<div>') .css({ 'background-color': 'rgba(255,0,0,.5)', 'position': 'absolute', 'z-index': '65535' }) .appendTo('body'); Basically, I'm injecting a div into the DOM that has a semi-transparent background. Then I listen for the mouseover event on every element, then move the div so that it covers that element. Right now, this just makes the whole page go red as soon as you move your mouse over the page. How can I get this to work nicer? Edit: Pretty sure the problem is that as soon as my mouse touches the page, the body gets selected, and then as I move my mouse around, none of the moments get passed through the highligher because its overtop of everything. Firebug Digging through Firebug source code, I found this: drawBoxModel: function(el) { // avoid error when the element is not attached a document if (!el || !el.parentNode) return; var box = Firebug.browser.getElementBox(el); var windowSize = Firebug.browser.getWindowSize(); var scrollPosition = Firebug.browser.getWindowScrollPosition(); // element may be occluded by the chrome, when in frame mode var offsetHeight = Firebug.chrome.type == "frame" ? FirebugChrome.height : 0; // if element box is not inside the viewport, don't draw the box model if (box.top > scrollPosition.top + windowSize.height - offsetHeight || box.left > scrollPosition.left + windowSize.width || scrollPosition.top > box.top + box.height || scrollPosition.left > box.left + box.width ) return; var top = box.top; var left = box.left; var height = box.height; var width = box.width; var margin = Firebug.browser.getMeasurementBox(el, "margin"); var padding = Firebug.browser.getMeasurementBox(el, "padding"); var border = Firebug.browser.getMeasurementBox(el, "border"); boxModelStyle.top = top - margin.top + "px"; boxModelStyle.left = left - margin.left + "px"; boxModelStyle.height = height + margin.top + margin.bottom + "px"; boxModelStyle.width = width + margin.left + margin.right + "px"; boxBorderStyle.top = margin.top + "px"; boxBorderStyle.left = margin.left + "px"; boxBorderStyle.height = height + "px"; boxBorderStyle.width = width + "px"; boxPaddingStyle.top = margin.top + border.top + "px"; boxPaddingStyle.left = margin.left + border.left + "px"; boxPaddingStyle.height = height - border.top - border.bottom + "px"; boxPaddingStyle.width = width - border.left - border.right + "px"; boxContentStyle.top = margin.top + border.top + padding.top + "px"; boxContentStyle.left = margin.left + border.left + padding.left + "px"; boxContentStyle.height = height - border.top - padding.top - padding.bottom - border.bottom + "px"; boxContentStyle.width = width - border.left - padding.left - padding.right - border.right + "px"; if (!boxModelVisible) this.showBoxModel(); }, hideBoxModel: function() { if (!boxModelVisible) return; offlineFragment.appendChild(boxModel); boxModelVisible = false; }, showBoxModel: function() { if (boxModelVisible) return; if (outlineVisible) this.hideOutline(); Firebug.browser.document.getElementsByTagName("body")[0].appendChild(boxModel); boxModelVisible = true; } Looks like they're using a standard div + css to draw it..... just have to figure out how they're handling the events now... (this file is 28K lines long) There's also this snippet, which I guess retrieves the appropriate object.... although I can't figure out how. They're looking for a class "objectLink-element"... and I have no idea what this "repObject" is. onMouseMove: function(event) { var target = event.srcElement || event.target; var object = getAncestorByClass(target, "objectLink-element"); object = object ? object.repObject : null; if(object && instanceOf(object, "Element") && object.nodeType == 1) { if(object != lastHighlightedObject) { Firebug.Inspector.drawBoxModel(object); object = lastHighlightedObject; } } else Firebug.Inspector.hideBoxModel(); }, I'm thinking that maybe when the mousemove or mouseover event fires for the highlighter node I can somehow pass it along instead? Maybe to node it's covering...?

    Read the article

  • mySQL - query to combine two tables

    - by W.Gerick
    Hi there, I have two tables. The first one holds information about cities: Locations: locID | locationID | locationName | countryCode | 1 | 2922239 | Berlin | de | 2 | 291074 | Paris | fr | 3 | 295522 | Orlando | us | 3 | 292345 | Tokyo | jp | There is a second table, which holds alternative names for locations. There might be NO alternative name for a location in the Locations table: AlternateNames: altNameID | locationID | alternateName | 1 | 2922239 | Berlino | 2 | 2922239 | Berlina | 3 | 291074 | Parisa | 4 | 291074 | Pariso | 5 | 295522 | Orlandola | 6 | 295522 | Orlandolo | What I would like to get is the locationID, name and the countryCode of a location for a location name search like "Berlin", or "Ber": | locationID | name | countryCode | | 2922239 | Berlin | de | However, if the user searches for "Berlino", I would like to get the alternateName back: | locationID | name | countryCode | | 2922239 | Berlino | de | The "locationName" has a higher priority than the alternateName, if the searchterm matches both. I can't figure out how to build a query to do that. Since the name can come from one of the two tables, it seems quite difficult to me. Any help is really appreciated!

    Read the article

  • implement a coverflow UI in an Android web application

    - by ravidor
    I am trying to build a coverflow UI on an Android web application using HTML,CSS, JavaScript and some images. CSS 3D transforms, which are supported in Safari sine 2009 and on the iPhone since version 2.0, is not supported well on the Android. worse then that, the implementation is buggy on Android 2.1 and Android 2.2, and in each version in a different way. Any idea how can I build a coverflow UI on an Android web application using HTML,CSS, JavaScript and some images without CSS 3D transforms?

    Read the article

  • I want actions not views.

    - by Ben
    Rails is doing my head in. I'm trying now to put something together to pull screen scraped data from site X through to client Y via a ruby script on server Z I don't want views, I just want the request to look like domain.com/action/method Inside routes.rb I have: match ':controller(/:action(/:id(.:format)))' But it still won't work. I just get ActionView::MissingTemplate in the log. Achtung! If I deliberately put a faulty method in that subsequently calls render - the log file indicates the method executed badly, so I don't think it's something wrong with the "action" controller.

    Read the article

  • Architecture of an image hosting site

    - by kamziro
    I'm sure many here are aware of image hosting sites, like imgur, min.us, photobucket etc. Not that I want to develop one, but besides just uploading the file, organising it in some directory somewhere, what architectural considerations are involved in these sites? Especially when there's millions of page views a day (like imgur, I'd imagine) I'm curious about this because it seems that a lot of sites (say, dating websites etc) would be pretty image intensive. Even if it's not for millions of page views, what are some basic architectural requirements of efficient image deliveries online?

    Read the article

  • Inserting Parameters, C#, T-Sql

    - by jpavlov
    I am trying to insert a parameter through an aspx page via text box. I set my parameters up, but evertime I executenonquery, the @Username shows up in the database instead of the actual value. Below is my code. Can anyone shed a little insight? SqlParameter @UserName = new SqlParameter("@UserName", System.Data.SqlDbType.VarChar); @UserName.Direction = ParameterDirection.Input; @UserName.Value = txtUserName.Text; cmd.Parameters.Add(@UserName);

    Read the article

  • How does a debug build make reverse engineering easy?

    - by danny
    Some answer here stated that debug info would make it easier to reverse engineer the software. When I use Visual C++ and distribute an executable with debugging information but without other files (.pdb), will it contain any interesting things? I looked to the executable with a hex editor and found nothing like symbol names, for now I assume the .exe file just links to information in the .pdb files, right? Do you know whether it contains variable names? function/member names? line numbers? anything interesting? Thanks!

    Read the article

  • WPF - Drag from withing DataTemplate

    - by Gustavo Cavalcanti
    I have a ListBox displaying employees with a DataTemplate - it looks very similar to this screenshot. I want to be able to click on the employee photo, drag it and drop it somewhere out of the ListBox. How can I do that? I am not sure how to capture the PreviewMouseLeftButtonDown event of the Image, since it's inside the DataTemplate. Edit: The DataTemplate lives in a separate assembly and the drag/drop logic needs to be in the Window that has the ListBox. Edit2: I am thinking that the right way of doing this is using commands, am I right? Thanks!

    Read the article

  • SQL WHERE clause not returning rows when field has NULL value

    - by JohnB
    Ok, so I'm aware of this issue: When SET ANSI_NULLS is ON, all comparisons against a null value evaluate to UNKNOWN SQL And NULL Values in where clause SQL Server return Rows that are not equal < to a value and NULL However, I am trying to query a DataTable. I could add to my query: OR col_1 IS NULL OR col_2 IS NULL for every column, but my table has 47 columns, and I'm building dynamic SQL (string concatenation), and it just seems like a pain to do that. Is there another solution? I was to bring back all the rows that have NULL values in the WHERE comparison. UPDATE Example of query that gave me problems: string query = col_1 not in ('Dorothy', 'Blanche') and col_2 not in ('Zborna', 'Devereaux') grid.DataContext = dataTable.Select(query).CopyToDataTable(); (didn't retrieve rows if/when col_1 = null and/or col_2 = null)

    Read the article

  • Program received signal from GDB: EXC_BAD_ACCESS

    - by user577185
    Well, I'm starting development on the Mac OS X this code that you'll see is in a book that I bought, really basic like Chapter 3. And I can't run it. PLEASE HELP ME: C301.m : #import <Foundation/Foundation.h> int main (int argc, const char * argv[]) { if (argc == 1) { NSLog (@"You need to provide a file name"); return -1; } FILE *wordFile = fopen("tmp/words.txt", "r"); char word[100]; while (fgets(word, 100, wordFile)) { word[strlen(word) - 1] = '\0'; NSLog(@"%s is %d characters long", word, strlen(word)); } fclose(wordFile); return 0; } //main The file is in its place. Thank you so much!

    Read the article

  • Hibernate mapping one-to-many problem

    - by Xorty
    Hello, I am not very experienced with Hibernate and I am trying to create one-to-many mapping. Here are relevant tables: And here are my mapping files: <hibernate-mapping package="com.xorty.mailclient.server.domain"> <class name="Attachment" table="Attachment"> <id name="id"> <column name="idAttachment"></column> </id> <property name="filename"> <column name="name"></column> </property> <property name="blob"> <column name="file"></column> <type name="blob"></type> </property> <property name="mailId"> <column name="mail_idmail"></column> </property> </class> </hibernate-mapping> <hibernate-mapping> <class name="com.xorty.mailclient.server.domain.Mail" table="mail"> <id name="id" type="integer" column="idmail"></id> <property name="content"> <column name="body"></column> </property> <property name="ownerAddress"> <column name="account_address"></column> </property> <property name="title"> <column name="head"></column> </property> <set name="receivers" table="mail_has_contact" cascade="all"> <key column="mail_idmail"></key> <many-to-many column="contact_address" class="com.xorty.mailclient.client.domain.Contact"></many-to-many> </set> <list name="attachments" cascade="save-update, delete" inverse="true"> <key column="mail_idmail" not-null="true"/> <index column="fk_Attachment_mail1"></index> <one-to-many class="com.xorty.mailclient.server.domain.Attachment"/> </list> </class> </hibernate-mapping> In plain english, one mail has more attachments. When I try to do CRUD on mail without attachments, everyting works just fine. When I add some attachment to mail, I cannot perform any CRUD operation. I end up with following trace: org.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch update at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:96) at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66) at org.hibernate.jdbc.AbstractBatcher.executeBatch(AbstractBatcher.java:275) at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:268) at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:184) at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:321) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:51) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1216) at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:383) at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:133) at domain.DatabaseTest.testPersistMailWithAttachment(DatabaseTest.java:355) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at junit.framework.TestCase.runTest(TestCase.java:168) at junit.framework.TestCase.runBare(TestCase.java:134) at junit.framework.TestResult$1.protect(TestResult.java:110) at junit.framework.TestResult.runProtected(TestResult.java:128) at junit.framework.TestResult.run(TestResult.java:113) at junit.framework.TestCase.run(TestCase.java:124) at junit.framework.TestSuite.runTest(TestSuite.java:232) at junit.framework.TestSuite.run(TestSuite.java:227) at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83) at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197) Caused by: java.sql.BatchUpdateException: Cannot add or update a child row: a foreign key constraint fails (`maildb`.`attachment`, CONSTRAINT `fk_Attachment_mail1` FOREIGN KEY (`mail_idmail`) REFERENCES `mail` (`idmail`) ON DELETE NO ACTION ON UPDATE NO ACTION) at com.mysql.jdbc.PreparedStatement.executeBatchSerially(PreparedStatement.java:1666) at com.mysql.jdbc.PreparedStatement.executeBatch(PreparedStatement.java:1082) at org.hibernate.jdbc.BatchingBatcher.doExecuteBatch(BatchingBatcher.java:70) at org.hibernate.jdbc.AbstractBatcher.executeBatch(AbstractBatcher.java:268) ... 27 more Thank you

    Read the article

  • MySQL SELECT MAX multiple tables : foreach parent return eldest son's picture

    - by Guillermo
    **Table parent** parentId | name **Table children** childId | parentId | pictureId | age **Table childrenPictures** pictureId | imgUrl no i would like to return all parent names with their eldest son's picture (only return parents that have children, and only consider children that have pictures) so i thought of something like : SELECT c.childId AS childId, p.name AS parentName, cp.imgUrl AS imgUrl, MAX(c.age) AS age FROM parent AS p RIGHT JOIN children AS c ON (p.parentId = c.parentId) RIGHT JOIN childrenPictures AS cp ON (c.pictureId = cp.pictureId)) GROUP BY p.name This query will return each parent's eldest son's age, but the childId will not correspond to the eldest sons id, so the output does not show the right sons picture. Well if anyone has a hint i'd appreciate very much Thank you very much, G

    Read the article

  • Java Regular Expressions

    - by david robers
    Hi All, Im struggling to understand the regex documentation. How would I find the strings that contain exactly one C in the following text: ABCCAMNL YOOBABCCA XNABCCA ZDXUABCCA TAQABCC ISABCCA REABCCA CABCAMONPT Edit: private void matchIt(String regex, ArrayList<String> d) { Pattern p = Pattern.compile("[\\w^C]"); Matcher m = p.matcher(regex); for (int i = 0; i < d.size(); i++) { p.matcher(d.get(i)); if(m.find()){ out.println(d.get(i)); } } } i have the above function and it only outputs: ABCCAMNL YOOBABCCA Why is that?

    Read the article

  • Java: where should I put anonymous listener logic code?

    - by tulskiy
    Hi, we had a debate at work about what is the best practice for using listeners in java: whether listener logic should stay in the anonymous class, or it should be in a separate method, for example: button.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { // code here } }); or button.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { buttonPressed(); } }); private void buttonPressed() { // code here } which is the recommended way in terms of readability and maintainability? I prefer to keep the code inside the listener and only if gets too large, make it an inner class. Here I assume that the code is not duplicated anywhere else. Thank you.

    Read the article

  • Free Dynamic DNS Nameservers

    - by Maxim Zaslavsky
    I recently set up a home server that I want to use as my primary hosting platform. So far, I've mapped some domains to it by setting up A records for them that point to my home IP. As my home IP can change randomly and without notice, however, I'm afraid of such downtime. Thus, I'm looking for a dynamic DNS solution. So far, I've set up DynDNS, but I haven't found a way to use dynamic DNS with an existing domain. Are there any free dynamic DNS nameserver services available?

    Read the article

  • CPU Temperature sensor wrong?

    - by Matias Nino
    Everest Ultimate is suddenly telling me that the CPU temperature (and core temps) for my E6850 Core 2 Duo is 72 degrees Celsius. When I stress-test the machine, the temp goes up to 91 degrees and the CPU actually throttles. System remains stable though. For over a year now, my CPU has run very cool (40's) with a large commercial copper heatsink/fan that I bought separately. To top it off, I removed the cover of the box and felt the cpu heatsink and it wasn't even warm. Is there such a thing as a CPU temp sensor showing the wrong readings? Any tips would help. UPDATE #1 Temp is also just as high in BIOS. So that leads me to believe it's a CPU seating issue (even though I used thermal paste to seat it two years ago when I built the machine) UPDATE #2 Well. I removed the heatsink and cleaned off the original thermal paste (which was somewhat crusty). I polished the surface, re-applied some new paste, and reseated the heat sink. After powering it up, there was no noticeable change in the temp - ideling at 74. Ran the stress test and it went up to 94 degrees before being 100% throttled. I let it sit at 94 degrees for 20 minutes straight and the computer didn't even flinch. I then immediately shut it off and opened the case and felt around. The heatsink was completely cold to the touch. Even the copper rods were cold. The area near contact with the CPU was slightly warm but not hot to touch. Then I ran REALTEMP, which is supposedly more accurate and it told me the CPU was at 104 degrees. (LOL) At this point, I'm thinking no doubt the cpu's sensor is wrong. Sidenote: the BIOS has the latest version so no option to flash there. Reverting hasn't been known to help from what I've read. What pisses me off is the false temps force the CPU to artificially throttle from 3GHz down to 2GHz and my CPU fan is cranking at full force all the time. Should I call intel and tell them to send me another E6850? SOLUTION UPDATE I switched the processor out with another one and got the same obscene temperatures with the new processor followed by a heatsink that was cool to touch. My suspicion in the heatsink was suddenly renewed. I swapped it out with the stock heatsink/fan and lo and behold the temperatures returned to the normal 35C-50C. Even though the thermal paste was visibly flattened out every time I removed it, it looks like the heatsink was still not pressing hard enough on the CPU to effectively conduct the heat. The heatsink is a Masscool 8Wa741, which screws into a standard position on a mount on the back of the MOBO. Only thing I can surmise after 2 years of use was that, over time, the heatsink pressure on the CPU gave way until the heat began to be ineffectively conducted. Lessons learned: Intel CPU's can run SUPER HOT (upwards of 95C) and still be stable. Heatsink's need to be VERY firmly pressed against the CPU to conduct heat.

    Read the article

  • How to make computer interface with circuit

    - by light.hammer
    I understand that I can build a circuit that will do whatever I like (ex: a simple circuit that will turn on a motor to open the blinds or something), and I can write a program that will automate my computer/mac however I like (ex: open this program at this time, or with this input and create a new file, ect). My question is, how can I interface the two? Is there an easy DIY or cheap commercial (or not cheap but functional) USB plug that will turn on/off from computer commands? I'm basically looking for some sort of on/off switch I can script/applescript. How would you even approach this problem, would I have to write my own driver some where along the way?

    Read the article

  • Computer speakers receive radio station signal

    - by squircle
    I have a set of Logitech 5.1 speakers where each speaker and the source plug into the subwoofer. I'm using a Griffin Firewave with output from my MacBook Pro, and output from my custom-built desktop with a switch in the middle (built it myself out of an old Belkin A/B parallel switch). Recently, I've noticed that I can hear a local Punjabi radio station being picked up by my speakers, and the volume of this interference increases as I increase the volume of the speakers. I'm fairly sure that this radio station is at the low-end of the FM spectrum, below 90MHz (or it may be at the high end, above 105MHz, my memory isn't infallible). It gets quite annoying as I can't put my audio very loud without the interference. I've tried to put a ferrite core on the input cable just before the 3.5mm jacks plug into the subwoofer. I don't know if putting the same core around all three of the cables (green, black, orange) would negate the effects, but I'm assuming not. There has been no change. Is there any reason why this would be happening? I'm assuming the interference is coming somewhere between the FireWave and the subwoofer, because the noise gets amplified with volume increases. If anybody has any suggestions, I'd be grateful!

    Read the article

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