next element in 2 array loop php

First of all, I apologize for my bad English. I have 2 array. First one is Sections and second one Lessons. I’m trying to get $next_lesson id element using this code: foreach ($sections as $key => $section): $lessons = $this->crud_model->get_lessons(‘section’, $section[‘id’])->result_array(); foreach ($lessons as $key => $lesson): $current_lesson = $lesson[‘id’]; $next = $lessons[$key+1]; $next_lesson =…

Details

I have a json =

I have input json= [ {“nm”:”BRANCHID”, “vl”:”1″},{“nm”:”TELLERID”,”vl”:”9903″ },{“nm”:”mobile”,”vl”:”9903234565″ } ] i need to check nm equal to BRANCHID or TELLERID then would set V1 value accordingly and output == {“BRANCHID”:”1″},{“TELLERID”,:”9903″ } Please help me

Details

JAVA: Exception in thread “JavaFX Application Thread” java.lang.RuntimeException: java.lang.reflect.InvocationTargetException ERROR

Hello I am new to java language. I keep getting this error Exception in thread “JavaFX Application Thread” java.lang.RuntimeException: java.lang.reflect.InvocationTargetException at javafx.fxml.FXMLLoader$MethodHandler.invoke(FXMLLoader.java:1774) at javafx.fxml.FXMLLoader$ControllerMethodEventHandler.handle(FXMLLoader.java:1657) at com.sun.javafx.event.CompositeEventHandler.dispatchBubblingEvent(CompositeEventHandler.java:86) at com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(EventHandlerManager.java:238) at com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(EventHandlerManager.java:191) at com.sun.javafx.event.CompositeEventDispatcher.dispatchBubblingEvent(CompositeEventDispatcher.java:59) at com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:58) at com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114) at com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56) at com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114) at com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56) at com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114) at com.sun.javafx.event.EventUtil.fireEventImpl(EventUtil.java:74) at com.sun.javafx.event.EventUtil.fireEvent(EventUtil.java:49) at javafx.event.Event.fireEvent(Event.java:198) at javafx.scene.Node.fireEvent(Node.java:8411) at javafx.scene.control.Button.fire(Button.java:185) at…

Details