Search Results

Search found 4054 results on 163 pages for 'surround sound'.

Page 71/163 | < Previous Page | 67 68 69 70 71 72 73 74 75 76 77 78  | Next Page >

  • SQL Server architecture - they want to move my database to new instance...Why?

    - by O'MALLEY
    Our current production database environment contains about 10 similarily managed databases. Our agency has just purchased and is installing new blade chasses and wants to move my database to a new instance (leaving the other 9 on another). This decision is being driven by one of our IT staff, not a DBA. I am a project manager, not a DBA but I know enough to not necesarrily have a good feeling about this decision and I am urging our IT department to make a sound decision based on what is best for the database. Our IT department has stated that it is not good to have all our eggs in one basket, and has also stated that my database contains "regulatory data" so it should be on its own instance. A couple of truths: - None of the databases on the current instance are OLTP databases nor are any of them data warehouses - My database currently has joins/views to a couple of the other databases in the production environment So my questions are as follows: Am I wrong to disregard a statement about eggs in baskets? (hello, this is why we have maintenance plans/disaster recovery plans). I'll mention that other databases also have regulatory data too. What types of questions do I need to ask to determine if this is a sound decicion? (A DBA friend mentioned that if the service level agreement of said database does not radically differ from the others then why do they want to do this?) I have done some research on linked servers. What arguments should I bring forth about the fact that I have views setup that rely on data from other DBs currently?

    Read the article

  • Is it possible for a faulty processor to cause audio static/noise?

    - by Tom
    I have a Core 2 Extreme processor I received from a friend and have set up an XBMC box using it. However, I constantly get audio static whenever playing any music or videos. Here is a video of the sound: http://www.youtube.com/watch?v=SqKQkxYRVA4 I have tried replacing everything short of the case and the processor, including cables, audio interfaces, operating systems, ram, etc, leading me to think it might be either the case shorting out the motherboards I have tried or a faulty processor. Is it possible for a faulty processor to cause audio static/noise? Any feedback would be appreciated. Edit - Here's a list of things I have tried: Reinstalling OS Installing/upgrading/repairing PulseAudio/Alsa Installing alternate OSes, straight Ubuntu, Lubuntu, Xubuntu, Arch, Mint, Windows 7 Switching audio from the external card to internal Optical, audio out through HDMI, audio out through headphones Different ports on receiver (my main desktop sounds fine on the same sound system) Different optical cables Unplugging everything unnecessary from the motherboard (1 HD, 1 Stick of Ram, 1 Keyboard) Swapping out ram Swapping out the motherboard Replacing the Graphics Card (was replaced due to fan being noisy, not specifically for this problem) Different harddrives Swapping power supply Disabling onboard audio Switching Power Cable Plugging in through surge protector Plugging into different outlet on separate circuit

    Read the article

  • What are these CPU cache settings? Snoop Filter, ACL prefetch, HW prefetch

    - by eater
    I was in my BIOS setup turning on VT-x support today and saw these other settings. A little googling indicates that they each seem to turn on some sort of optimization to do with the CPU's L2 cache. They were all turned off by default. The processor in question is an Intel Xeon quad-core 3.4GHz (X5492). My OS is Linux 2.6.35.10-74.fc14.x86_64 #1 SMP Thu Dec 23 16:04:50 UTC 2010 x86_64 x86_64 x86_64 GNU/Linux. I have 4GB of RAM if that matters. Here's what the BIOS manufacturer has to say: Snoop Filter Enabling the snoop filter typically improves performance by reducing snoop traffic on the frontside bus in dual processor configurations. Well I like the sound of improved performance. Why would the BIOS have this off by default? Or by dual processor do they not mean multi-core? Regardless, is there a downside if this is on? ACL Prefetch When enabled, the Adjacent Cache Line Prefetcher fetches both cache lines that comprise a cache line pair when it determines required data is not currently in its cache. When disabled, the processor will only fetch the cache line required by the processor. HW Prefetch Fetches an extra line of data into L2 from external memory. Both of these sound like optimizations that have some drawbacks. What are the reasons to turn them on? What are the reasons to leave them off. Why is the default off?

    Read the article

  • Windows freezes when watching videos

    - by cornerback84
    I have Acer laptop Aspire 5740 - 5780 with windows 7 Ultimate 32 bit. I am using Chrome. Windows is 1 year old, but it's not the first time this has happened. Windows freezes whenever I am watching videos on facebook/youtube or when using SopCast. I thought there was some faulty plugin, so I recently re-installed chrome but it happened again. No keys work, and the sound of whatever I am listening starts repeating like grrrr..drrrr. Its seems like the sound in very slow motion. One time I left it in this freeze state for 5 min and it recovered automatically. It usually does not happen when I am using windows media player. I had some codecs installed but I removed them to see if that fixes. So far, I have narrowed it down to youtube/footytube videos and sopcast. I have checked event logs but nothing special. Is there any way I can narrow down the problem or any suggestions on how to fix it. I'd like to add that it does not always happen. Sometimes windows goes days/weeks without freezing, and sometimes it take a min into video to freeze.

    Read the article

  • Flash Backed Write Cache (FBWC) without capacitor pack

    - by Martyn
    I brought a HP Smart Array P410 controller and it is installed and working fine in a HP Prolient Microserver with 4 drives in two RAID 1 arrays. I didn’t realise however that it came without any cache so would only work by directly writing straight to the disk, and the performance was horrible. So I then brought the 512MB Flash Backed Write Cache (FBWC) memory module as I was under the impression that with FBWC I would not need a battery. I got this idea from a forum post. "What do you guys think of the choice between 'BBWC' (battery backed write cache) and 'FBWC' (flash backed write cache)? The flashed based ones use non-volitile memory so need no battery." After installing the cache module however the server pretty much won’t boot. The P410 has a flashing amber light on it, and from the manual that doesn’t sound good. I’ve managed to get to the on board BIOS once and even managed to get to boot to the HP Array Configuration Utility (ACU) CD once, but every other time the Server continuingly reboots once it get to the POST screen and reads ARRAY INITILIZING %%%. The one time I reached the ACU, it reported a problem with the Cache Module. To me, it seems like the cache module is faulty, however the supplier tells me “Do you have an FBWC battery pack, p/n 587324-001, because that is required for the cache to work. If you have it, please complete an RMA form and we'll send a replacement / credit.” Does this sound right to you? I’ve been ordering the parts from the US and I don’t want to spend $77 + $40 p&p on a battery, wait a week for the shipping to find the card is faulty, and I don’t want to send back a working card?

    Read the article

  • Getting old bluetooth headset out of standby on Windows 7

    - by luagh45
    I think this is the problem, and if not, I'm open to suggestions. I have an old Jabra BT200 that I used to use on my phone. When a phone call was coming in it would beep using its own noises (meaning the phone never rang inside the headset) and then I could push the 'answer/hang up' button and sound and mic would start working. I have now paired it with Windows 7, and it looks good. Under the playback menu I have 'Bluetooth Hands free Audio / Jabra BT200 (Mono Audio) / Ready', and under the recording menu I have 'Bluetooth Audio Input Device / Jabra BT200 (Mono Audio) / Ready'. However when I try to test the speakers Windows sends a sound, but I never hear it, and when I talk in the mic, Windows never hears me. If I right click either the Bluetooth mic or speakers there's an option to 'Connect', but it's grayed out and I cannot click it. As the final piece of knowledge I have, my headset blinks once every 3 seconds when it's in standby and I can't get that to change. If everything was working it should blink once every second at which point I think all of my problems would be fixed. Hence my issue: I can't seem to get my headset out of standby. On my headset I've tried sending it test noises and then pressing the 'Answer' button, but still nothing. The headset beeps when I press it, so it works, it just doesn't ever come out of standby. Is there maybe some way to trick my headset into thinking it's getting a phone call from my computer?

    Read the article

  • Proper approach to debug PC startup problems (POST)

    - by saurabhj
    My CPU was heating up to around 65 deg C and last time this had happened (about a year ago), I got thermal paste put between the CPU and heat sink and this managed to get it down to about 45 - 50 degrees. This time, I got some thermal paste and put it myself. However, my PC is not showing the POST display and not starting up. This is what happens LEDs light up HDDs spin Mouse is getting power All fans including the processor fan starts No display on monitor No diagnostic beep sounds (no sounds at all) What I have tried Removing everything including RAM, HDD, PCI cards, AGP card Boot up machine No changes from first state. What steps can I take to figure out where the problem lies? Note (might be important) When I removed the heat sink, the processor came out with it (it was stuck to it inspite of the processor latch on) Had to pry it separate with a screw-driver. Configuration Pentium 4, 2.8 Ghz with HT (very old, I know) Original Intel Mobo with onboard sound and graphics (GB series) 2x512 Mb DDR-RAM 2 SATA disks (320 Gigs / 250 gigs) DVD Writer Creative Sound Card Network card Any help would be appreciated. Thanks!

    Read the article

  • Why is my Toshiba Satellite L675D laptop not connecting to my HD TV using an HDMI cord?

    - by Akasha Eyre
    I'm having a problem connecting my Toshiba Satellite L675 laptop to my Samsung HD TV. I've done it before using an HDMI cord but now, for some odd reason, it's not connecting at all. My computer screen before would go completely black for a second & then come back & (with it being attached to the TV with the HDMI cord & it being on the proper channel) it would make a sound, come on & work beautifully. Now, I try hooking it up & it doesn't do anything. No black screen, no sound. The TV screen just says there's no connection & that I need to check out the power source. I'm still checking around, trying to find out if there's a virus in my computer (since my dad & I have the same computer & he can connect his to the TV with no problems), or if I deleted something that had to do with the connection. I've tried turning my computer off & letting it sit for a while, I've tried checking out other websites & have come up with nothing.

    Read the article

  • Windows Vista freezes

    - by Kakurady
    Windows Vista (32-bit) would randomly freeze on my computer, usually 15-30 minutes after login but can happen just after login. All applications would stop responding and the hard drive will not make any sound, and after a while, the mouse cursor will also stop moving. I dual-boot Ubuntu, and that still works fine. It started with the computer freezing when loading Team Fortress 2. Alt-Tab and Ctrl-Alt-Del have no effect, and the hard drive does not make any sound. I tried to verify the game data using Steam and that freezes the computer too. So I stupidly reinstalled the game. Now the game doesn't freeze when it starts, but instead the whole computer randomly freezes. This computer is a Dell XPS M1530 with a 320GB (298GiB) drive (WDC WD3200BEVT-7) split 5-ways, with Windows and Linux a partition each, one more for Linux swap space, and another two partitions for Dell diagnostic program and factory image and drivers. There was once where the hard drive would make clicking noises all day, and only stopped when I rebooted the computer. Since then, the BIOS diagnostics would fail the drive (for "self-test log contains previous errors") whenever ran. (The on-disk diagnostics cannot be run because I overwrote the MBR with GRUB.) Naturally, I thought the hard drive could be the problem. CHKDSK found one bad sector, but this seems to have no effect. System File Checker found two protected files with wrong hashes, one is some kind of IE manifest, and the other is a tcpmon.ini. Neither of them can be restored because their back up copy also have wrong hashes. Nothing about system failures in the event viewer. What should I do next?

    Read the article

  • Microphone array support in Windows. Info on performance and compatible hardware?

    - by exinocactus
    It is officially claimed by Microsoft (Audio Device Technologies for Windows), that Windows Vista has an integrated system-level support of microphone arrays for improved sound capturing by isolating a sound source in target direction and rejecting ambient noise and reverberation. In more technical terms, an implementation of an adaptive beamformer. Theoretically, microphone arrays with 2-4 mics can substantially improve SNR under some conditions like speaker in front of the laptop in noisy environment (airport, cafe). Surprisingly, though, I find very little information about commercially-available products supporting these new features. I mean products like portable usb micropone arrays or laptops or flat screens with integrated mic arrays. I could only find info about two laptop models having "noise cancelling digital array microphone". These are Dell Latitude and Eee PC 1008P-KR. Now my questions: Do you have any experience with the Windows beamformer implementation? For instance, in the above mentioned laptops. How well does it work? Are there any tests results available in the net or in print (papers?)? Do you know about other microphone array hardware? What could be the reason why mic array technology didn't get sucess Is there mic arrays support in 'Windows 7'?

    Read the article

  • Disk operations in windows 7 are slow

    - by Skadlig
    My computer started lagging last Sunday. I tried to reboot it and it failed. Trying to boot into failsafe mode takes around two hours. It mainly freezes on two files: scsiport.sys and classpnp.sys When it finally has started all disc operations are really slow. When it has run for a while it goes faster, probably due to data moved into RAM instead. It froze on an other file before that was associated with Avast but uninstalling it didn't really help. A critical windows update was installed on Sunday but rolling back the update didn't help. I had a guess about the sound card but disabling the sound card drivers also didn’t help. I have an inkling of an idea that it might be Intel rapid storage technology that might be acting up but it doesn't allow me to reinstall it from failsafe mode and I haven't been able to log into normal mode for a while. I would appreciate suggestions regarding how to get into normal mode again and/or what can be the root cause.

    Read the article

  • Computer freezes after watching Youtube videos

    - by Roberts
    I had Windows 7 installed all september. But I installed Windows XP Professional back because my computer couldn't handle the new OS. After first boot I tried to install newest flash player (from Adobe website), but it failed. I had my old setup on USB drive and it worked. I don't know is it important or not. I am watching Youtube videos in my free time (almost every hour). After few days the computer started to freeze when I open a page with the video or close the page with video, not while I watch a video. No BSODs. Nothing in Event viewer. I use Firefox only. When computer freezes the sound wont. If iTunes is playing a radio station or is it another video playing in background, the sound wont freeze. Last few days the mouse wont freeze. Its a strange symptom. If I click few times then the cursor will actually freeze. I just want to know where does this problem come from (hardware - graphics card, old motherboard or it's just some glitch in setups). If it's not graphics card then I will be happy. The graphics card is ATI Radeon HD 4650 - brand new. Catalyst 11.8 installed. Things I have tried: Installed newest flash player after a week (the setup didn't fail this time) Installed latest video drivers Deleting cookies Defragmenting hard drive Using TuneUp utilities for computer cleenup Installed latest Mozilla Firefox Cleaned the PC Changed CPU Fan speed almost to max (just to be sure) Things I haven't tried yet: Didn't try playing videos on other browsers What can I do now?

    Read the article

  • Duplicate monitor on highest resolution in Windows 7

    - by AlexanderMP
    I have a monitor with a native resolution of 2560x1440, connected through display port. I also have an AV Receiver connected to the video card via HDMI, to have surround sound in games. All using Radeon HD 5670 (will upgrade soon to HD 7850). The problem is that my computer detects the receiver as a separate monitor, with the highest available resolution of 1920x1080. I have 3 options: Disconnect the second display. But then the sound (digital audio output through video card) also disappears. Duplicate displays. But then my primary monitor resolution is reduced to a maximum of just 1920x1080, that being the maximum of the second monitor. Extend desktop. This is the solution I picked so far, it being the least evil. The problems I face in this situations are 2: I have a blank part of the desktop where I sometimes lose my mouse pointer, so I made the extension small, 640x480, and placed it in a corner; when I turn off the main display, all windows resize to 640x480. In Kubuntu I had the option to duplicate the displays, while keeping the higher resolution. Which was great. I tried overriding using the Win7 netbook hack, but it's not available on non-netbooks. Is there a similar solution for this problem in Windows 7?

    Read the article

  • How to disable multiple touches on a ScrollView and UIImage

    - by Rob
    I have a scrollview that I am loading images into that the user can touch and play a sound. However, the program is getting confused when I press one image with one finger and then another one with a different finger. It thinks you are pushing the same button again and therefore plays the sound again (so you have two of the same sounds playing at the same time even though you may have pressed a different sound button). I tried setting exclusiveTouch for each UIImage but that didn't seem to work in this case for some reason. What am I missing or is there a better way to do this? Here is some code: for creating buttons.... - (void) createButtons { CGRect myFrame = [self.outletScrollView bounds]; CGFloat gapX, gapY, x, y; int columns = 3; int myIndex = 0; int viewWidth = myFrame.size.width; int buttonsCount = [g_AppsList count]; float actualRows = (float) buttonsCount / columns; int rows = buttonsCount / columns; int buttonWidth = 100; int buttonHeight = 100; if (actualRows > rows) rows++; //set scrollview content size to hold all the glitter icons library gapX = (viewWidth - columns * buttonWidth) / (columns + 1); gapY = gapX; y = gapY; int contentHeight = (rows * (buttonHeight + gapY)) + gapY; [outletScrollView setContentSize: CGSizeMake(viewWidth, contentHeight)]; UIImage* myImage; NSString* buttonName; //center all buttons to view int i = 1, j = 1; for (i; i <= rows; i++) { //calculate gap between buttons gapX = (viewWidth - (buttonWidth * columns)) / (columns + 1); if (i == rows) { //this is the last row, recalculate gap and pitch gapX = (viewWidth - (buttonWidth * buttonsCount)) / (buttonsCount + 1); columns = buttonsCount; }//end else x = gapX; j = 1; for (j; j <= columns; j++) { //get shape name buttonName = [g_AppsList objectAtIndex: myIndex]; buttonName = [NSString stringWithFormat: @"%@.png", buttonName]; myImage = [UIImage imageNamed: buttonName]; TapDetectingImageView* imageView = [[TapDetectingImageView alloc] initWithImage: myImage]; [imageView setFrame: CGRectMake(x, y, buttonWidth, buttonHeight)]; [imageView setTag: myIndex]; [imageView setContentMode:UIViewContentModeScaleToFill]; [imageView setUserInteractionEnabled: YES]; [imageView setMultipleTouchEnabled: NO]; [imageView setExclusiveTouch: YES]; [imageView setDelegate: self]; //add button to current view [outletScrollView addSubview: imageView]; [imageView release]; x = x + buttonWidth + gapX; //increase button index myIndex++; }//end for j //increase y y = y + buttonHeight + gapY; //decrease buttons count buttonsCount = buttonsCount - columns; }//end for i } and for playing the sounds... - (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event { //stop playing theAudio.stop; // cancel any pending handleSingleTap messages [NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(handleSingleTap) object:nil]; UITouch* touch = [[event allTouches] anyObject]; NSString* filename = [g_AppsList objectAtIndex: [touch view].tag]; NSString *path = [[NSBundle mainBundle] pathForResource: filename ofType:@"m4a"]; theAudio=[[AVAudioPlayer alloc] initWithContentsOfURL:[NSURL fileURLWithPath:path] error:NULL]; theAudio.delegate = self; [theAudio prepareToPlay]; [theAudio setNumberOfLoops:-1]; [theAudio setVolume: g_Volume]; [theAudio play]; } - (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event { BOOL allTouchesEnded = ([touches count] == [[event touchesForView:self] count]); if (allTouchesEnded) { //stop playing theAudio.stop; }//end if //stop playing theAudio.stop; }

    Read the article

  • problem processing xml in flex3

    - by john
    Hi All, First time here asking a question and still learning on how to format things better... so sorry about the format as it does not look too well. I have started learning flex and picked up a book and tried to follow the examples in it. However, I got stuck with a problem. I have a jsp page which returns xml which basically have a list of products. I am trying to parse this xml, in other words go through products, and create Objects for each product node and store them in an ArrayCollection. The problem I believe I am having is I am not using the right way of navigating through xml. The xml that is being returned from the server looks like this: <?xml version="1.0" encoding="ISO-8859-1"?><result type="success"> <products> <product> <id>6</id> <cat>electronics</cat> <name>Plasma Television</name> <desc>65 inch screen with 1080p</desc> <price>$3000.0</price> </product> <product> <id>7</id> <cat>electronics</cat> <name>Surround Sound Stereo</name> <desc>7.1 surround sound receiver with wireless speakers</desc> <price>$1000.0</price> </product> <product> <id>8</id> <cat>appliances</cat> <name>Refrigerator</name> <desc>Bottom drawer freezer with water and ice on the door</desc> <price>$1200.0</price> </product> <product> <id>9</id> <cat>appliances</cat> <name>Dishwasher</name> <desc>Large capacity with water saver setting</desc> <price>$500.0</price> </product> <product> <id>10</id> <cat>furniture</cat> <name>Leather Sectional</name> <desc>Plush leather with room for 6 people</desc> <price>$1500.0</price> </product> </products></result> And I have flex code that tries to iterate over products like following: private function productListHandler(e:JavaFlexStoreEvent):void { productData = new ArrayCollection(); trace(JavaServiceHandler(e.currentTarget).response); for each (var item:XML in JavaServiceHandler(e.currentTarget).response..product ) { productData.addItem( { id:item.id, item:item.name, price:item.price, description:item.desc }); } } with trace, I can see the xml being returned from the server. However, I cannot get inside the loop as if the xml was empty. In other words, JavaServiceHandler(e.currentTarget).response..product must be returning nothing. Can someone please help/point out what I could be doing wrong. My JavaServiceHandler class looks like this: package com.wiley.jfib.store.data { import com.wiley.jfib.store.events.JavaFlexStoreEvent; import flash.events.Event; import flash.events.EventDispatcher; import flash.net.URLLoader; import flash.net.URLRequest; public class JavaServiceHandler extends EventDispatcher { public var serviceURL:String = ""; public var response:XML; public function JavaServiceHandler() { } public function callServer():void { if(serviceURL == "") { throw new Error("serviceURL is a required parameter"); return; } var loader:URLLoader = new URLLoader(); loader.addEventListener(Event.COMPLETE, handleResponse); loader.load(new URLRequest(serviceURL)); // var httpService:HTTPService = new HTTPService(); // httpService.url = serviceURL; // httpService.resultFormat = "e4x"; // httpService.addEventListener(Event.COMPLETE, handleResponse); // httpService.send(); } private function handleResponse(e:Event):void { var loader:URLLoader = URLLoader(e.currentTarget); response = XML(loader.data); dispatchEvent(new JavaFlexStoreEvent(JavaFlexStoreEvent.DATA_LOADED) ); // var httpService:HTTPService = HTTPService(e.currentTarget); // response = httpService.lastResult.product; // dispatchEvent(new JavaFlexStoreEvent(JavaFlexStoreEvent.DATA_LOADED) ); } } } Even though I refer to this as mine and it is not in reality. This is from a Flex book as a code sample which does not work, go figure. Any help is appreciated. Thanks john

    Read the article

  • Iterables.find and Iterators.find - instead of throwing exception, get null

    - by mjlee
    I'm using google-collections and trying to find the first element that satisfies Predicate if not, return me 'null'. Unfortunately, Iterables.find and Iterators.find throws NoSuchElementException when no element is found. Now, I am forced to do Object found = null; if ( Iterators.any( newIterator(...) , my_predicate ) { found = Iterators.find( newIterator(...), my_predicate ) } I can surround by 'try/catch' and do the same thing but for my use-cases, I am going to encounter many cases where no-element is found. Is there a simpler way of doing this?

    Read the article

  • SQL Try catch purpose unclear

    - by PaN1C_Showt1Me
    Let's suppose I want to inform the application about what happened / returned the SQL server. Let's have this code block: BEGIN TRY -- Generate divide-by-zero error. SELECT 1/0; END TRY BEGIN CATCH SELECT ERROR_NUMBER() AS ErrorNumber, ERROR_SEVERITY() AS ErrorSeverity, ERROR_STATE() as ErrorState, ERROR_PROCEDURE() as ErrorProcedure, ERROR_LINE() as ErrorLine, ERROR_MESSAGE() as ErrorMessage; END CATCH; GO and Let's have this code block: SELECT 1/0; My question is: Both return the division by zero error. What I don't understand clearly is that why I should surround it with the try catch clausule when I got that error in both cases ? Isn't it true that this error will be in both cases propagated to the client application ?

    Read the article

  • Does a C# using statement perform try/finally?

    - by Lirik
    Suppose that I have the following code: private void UpdateDB(QuoteDataSet dataSet, Strint tableName) { using(SQLiteConnection conn = new SQLiteConnection(_connectionString)) { conn.Open(); using (SQLiteTransaction transaction = conn.BeginTransaction()) { using (SQLiteCommand cmd = new SQLiteCommand("SELECT * FROM " + tableName, conn)) { using (SQLiteDataAdapter sqliteAdapter = new SQLiteDataAdapter()) { sqliteAdapter.Update(dataSet, tableName); } } transaction.Commit(); } } } The C# documentation states that with a using statement the object within the scope will be disposed and I've seen several places where it's suggested that we don't need to use try/finally clause. I usually surround my connections with a try/finally, and I always close the connection in the finally clause. Given the above code, is it reasonable to assume that the connection will be closed if there is an exception?

    Read the article

  • I can't upload mp3 files using Codeigniter

    - by Drew
    There are lots of suggested fixes for this but none of them work for me. I have tried making the upload class (using the following methods: http://codeigniter.com/forums/viewthread/148605/ and http://codeigniter.com/forums/viewthread/125441/). When i try to upload an mp3 i get the error message "The filetype you are attempting to upload is not allowed". Below is my code for my model and my form (i've got a very skinny controller). If someone could help me out with this I would be eternally grateful. --Model-- function do_upload() { $soundfig['upload_path'] = './uploads/nav'; $soundfig['allowed_types'] = 'mp3'; $this->load->library('upload', $soundfig); if ( ! $this->upload->do_upload()) { $error = array('error' => $this->upload->display_errors()); return $error; } else { /* $data = $this->upload->data('userfile'); */ $sound = $this->upload->data(); /* $full_path = 'uploads/nav/' . $data['file_name']; */ $sound_path = 'uploads/nav/' . $sound['file_name']; if($this->input->post('active') == '1'){ $active = '1'; }else{ $active = '0'; } $spam = array( /* 'image_url' => $full_path, */ 'sound' => $sound_path, 'active' => $active, 'url' => $this->input->post('url') ); $id = $this->input->post('id'); $this->db->where('id', $id); $this->db->update('NavItemData', $spam); return true; } } --View - Form-- <?php echo form_open_multipart('upload/do_upload');?> <?php if(isset($buttons)) : foreach($buttons as $row) : ?> <h2><?php echo $row->name; ?></h2> <!-- <input type="file" name="userfile" size="20" /><br /> --> <input type="file" name="userfile" size="20" /> <input type="hidden" name="oldfile" value="<?php echo $row->image_url; ?>" /> <input type="hidden" name="id" value="<?php echo $row->id; ?>" /> <br /><br /> <label>Url: </label><input type="text" name="url" value="<?php echo $row->url; ?>" /><br /> <input type="checkbox" name="active" value="1" <?php if($row->active == '1') { echo 'checked'; } ?> /><br /><br /> <input type="submit" value="submit" /> </form> <?php endforeach; ?> <?php endif; ?>

    Read the article

  • localtime_r supposed to be thread safe, but causing errors in Valgrind DRD

    - by Nik
    I searched google as much as I could but I couldn't find any good answers to this. localtime_r is supposed to be a thread-safe function for getting the system time. However, when checking my application with Valgrind --tool=drd, it consistantly tells me that there is a data race condition on this function. Are the common search results lying to me, or am I just missing something? It doesn't seem efficient to surround each localtime_r call with a mutex, especially if it is supposed to by thread safe in the first place. here is how i'm using it: timeval handlerTime; gettimeofday(&handlerTime,NULL); tm handlerTm; localtime_r(&handlerTime.tv_sec,&handlerTm); Any ideas?

    Read the article

  • mediaplayer failure exception

    - by Rahulkapil
    I am working on an android application in which i have to play random sounds from my assets folder. there are some images also, when i click on any image from those images a sound must play regarding to that image from assets folder. i managed all but sometime my mediaplayer fails unexpectedly. I am attaching my code also. private Handler threadHandler = new Handler() { public void handleMessage(android.os.Message msg) { /*first*/ try{ InputStream ims1 = getAssets().open("images/" +dataAll_pic_name1); d1 = Drawable.createFromStream(ims1, null); rl1.setVisibility(View.VISIBLE); img1.setImageDrawable(d1); AssetFileDescriptor afd = getAssets().openFd("sounds/" + str_snd1); mp2 = new MediaPlayer(); mp2.setDataSource(afd.getFileDescriptor(),afd.getStartOffset(),afd.getLength()); mp2.prepare(); mp2.start(); mp2.setOnCompletionListener(new OnCompletionListener() { @Override public void onCompletion(MediaPlayer mp) { /*second*/ try{ InputStream ims2 = getAssets().open("images/" +dataAll_pic_name2); d2 = Drawable.createFromStream(ims2, null); rl2.setVisibility(View.VISIBLE); img2.setImageDrawable(d2); AssetFileDescriptor afd = getAssets().openFd("sounds/" + str_snd2); mp2 = new MediaPlayer(); mp2.setDataSource(afd.getFileDescriptor(),afd.getStartOffset(),afd.getLength()); mp2.prepare(); mp2.start(); mp2.setOnCompletionListener(new OnCompletionListener() { @Override public void onCompletion(MediaPlayer mp) { /*third*/ try{ InputStream ims3 = getAssets().open("images/" +dataAll_pic_name3); d3 = Drawable.createFromStream(ims3, null); rl3.setVisibility(View.VISIBLE); img3.setImageDrawable(d3); AssetFileDescriptor afd = getAssets().openFd("sounds/" + str_snd3); mp2 = new MediaPlayer(); mp2.setDataSource(afd.getFileDescriptor(),afd.getStartOffset(),afd.getLength()); mp2.prepare(); mp2.start(); mp2.setOnCompletionListener(new OnCompletionListener() { @Override public void onCompletion(MediaPlayer mp) { /*four*/ try{ InputStream ims4 = getAssets().open("images/" +dataAll_pic_name4); d4 = Drawable.createFromStream(ims4, null); rl4.setVisibility(View.VISIBLE); img4.setImageDrawable(d4); AssetFileDescriptor afd = getAssets().openFd("sounds/" + str_snd4); mp2 = new MediaPlayer(); mp2.setDataSource(afd.getFileDescriptor(),afd.getStartOffset(),afd.getLength()); mp2.prepare(); mp2.start(); mp2.setOnCompletionListener(new OnCompletionListener() { @Override public void onCompletion(MediaPlayer mp) { startAnimation(); //randomSoundPlay(); timer.schedule( new TimerTask(){ public void run() { System.out.println("Wait, what........................:"); try{ AssetFileDescriptor afd = getAssets().openFd("sounds/" + dataAll_sound_name); mp2 = new MediaPlayer(); mp2.setDataSource(afd.getFileDescriptor(),afd.getStartOffset(),afd.getLength()); mp2.prepare(); mp2.start(); mp2.setOnCompletionListener(new OnCompletionListener() { @Override public void onCompletion(MediaPlayer mp) { vg1.setClickable(true); vg2.setClickable(true); vg3.setClickable(true); vg4.setClickable(true); btn_spkr.setVisibility(View.VISIBLE); txtImage(); } }); }catch(Exception e){ e.printStackTrace(); } } }, delay_que); } }); }catch(Exception e){ e.printStackTrace(); } } }); }catch(Exception e){ e.printStackTrace(); } } }); }catch(Exception e){ e.printStackTrace(); } } }); }catch(Exception e){ e.printStackTrace(); } } }; in above code random images and sound sets in my activity. now when i click on any image a sound must play but sometimes it fails.. i tried but unable to resolve this issue. help me out. thanks in advance.

    Read the article

  • web2py server-side comments

    - by MikeWyatt
    In a web2py view, how do I comment out server-side code? In ASP.NET, I can surround any HTML or code tags with <%-- and --% and that block will not be compiled or sent to the client. Velocity does the same thing with #* and *#. Is there an equivalent in web2py? ASP.NET <div> <p><%=foo.bar%></p> <%-- don't print twice! <p><%=foo.bar%></p> --%> </div> web2py <div> <p><%=foo.bar%></p> ??? don't print twice! <p><%=foo.bar%></p> ??? </div>

    Read the article

  • Problems uploading different file types in codeigniter

    - by Drew
    Below is my script that i'm using to upload different files. All the solutions I've found deal only with multiple image uploads. I am totally stumped for a solution on this. Can someone tell me what it is i'm supposed to be doing to upload different files in the same form? Thanks function do_upload() { $config['upload_path'] = './uploads/nav'; $config['allowed_types'] = 'gif|jpg|png'; $config['max_size'] = '2000'; $this->load->library('upload', $config); if ( ! $this->upload->do_upload('userfile')) { $error = array('error' => $this->upload->display_errors()); return $error; } else { $soundfig['upload_path'] = './uploads/nav'; $soundfig['allowed_types'] = 'mp3|wav'; $this->load->library('upload', $soundfig); if ( ! $this->upload->do_upload('soundfile')) { $error = array('error' => $this->upload->display_errors()); return $error; } else { $data = $this->upload->data('userfile'); $sound = $this->upload->data('soundfile'); $full_path = 'uploads/nav/' . $data['file_name']; $sound_path = 'uploads/nav/' . $sound['file_name']; if($this->input->post('active') == '1'){ $active = '1'; }else{ $active = '0'; } $spam = array( 'image_url' => $full_path, 'sound' => $sound_path, 'active' => $active, 'url' => $this->input->post('url') ); $id = $this->input->post('id'); $this->db->where('id', $id); $this->db->update('NavItemData', $spam); return true; } } } Here is my form: <?php echo form_open_multipart('upload/do_upload');?> <?php if(isset($buttons)) : foreach($buttons as $row) : ?> <h2><?php echo $row->name; ?></h2> <input type="file" name="userfile" size="20" /><br /> <input type="file" name="soundfile" size="20" /> <input type="hidden" name="oldfile" value="<?php echo $row->image_url; ?>" /> <input type="hidden" name="id" value="<?php echo $row->id; ?>" /> <br /><br /> <label>Url: </label><input type="text" name="url" value="<?php echo $row->url; ?>" /><br /> <input type="checkbox" name="active" value="1" <?php if($row->active == '1') { echo 'checked'; } ?> /><br /><br /> <input type="submit" value="submit" /> </form> <?php endforeach; ?> <?php endif; ?>

    Read the article

  • Implementing Google Search Appliance results into website

    - by Adam Jenkin
    I’m interested to hear peoples preferred methods or approaches to implementing the search results from a Google Search Appliance into an existing website. More specifically how do people prefer to implement/embed the search results into their existing site and persist the surrounding website elements (menus, membership etc) around the search results. As far as I am aware there are 3 different approaches. Sub-domain, handle everything in the xslt – create a search.mysite.com which is completely handled by google xslt and embed surround site components in xslt. Embed search results into existing site using an iframe – Use the existing website and just use an iframe to import results into page. Embed results into existing site by using server side processing – This is how I have previously integrated search into a site using a combination of bespoke dev and the GSALib project. I would be interested to hear if anyone has other suggestions, and were people have benefited or regretted using the above approaches.

    Read the article

  • [Single|Double|Or no] Quotes when using grep?

    - by Hamy
    Grep acts differently depending on what kind of quotes I surround the regex with. I can't seem to get a clear understanding of why this is. Here is an example of the problem: hamiltont$ grep -e show\( test.txt variable.show(); variable.show(a); variable.show(abc, 132); variableshow(); hamiltont$ grep -e "show\(" test.txt grep: Unmatched ( or \( hamiltont$ grep -e 'show\(' test.txt grep: Unmatched ( or \( I am just assuming there is some proper way to enclose the regex with single/double quotes. Any help? FWIW, grep --version returns grep (GNU grep) 2.5.1

    Read the article

< Previous Page | 67 68 69 70 71 72 73 74 75 76 77 78  | Next Page >